Results 1 to 5 of 5
  1. #1
    2 Star Lounger
    Join Date
    Mar 2001
    Location
    Colorado, USA
    Posts
    144
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Date Mismatch Between Preview and Print (Access 2000)

    I've got a report that is opened from a form that specifies a date range through the use of two Date/Time Picker controls. The query on which the report is based references these fields and a control in the report header also points to these controls through the control source property as follows: ="Users With No Input From " & Format([Forms]![frmPrintReports]![acxFromDate], "Short Date") & " to " & Format([Forms]![frmPrintReports]![acxToDate], "Short Date"). When I preview the report, the dates displayed in the header are correct, but when I print the report the date is set to 12/30/99. I've encountered this problem before when the form gets closed before the report gets printed so I suspected that to be the problem here. I checked and the form is still open, but hidden until the report is closed. At this point the Print Reports forme is redisplayed.

    Any ideas of what's happening here? How can I ensure that the date displayed in the preview also gets on the printed version?

    Thanks for the help.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date Mismatch Between Preview and Print (Access 2000)

    What happens if you leave the form visible when the report is open?

  3. #3
    2 Star Lounger
    Join Date
    Mar 2001
    Location
    Colorado, USA
    Posts
    144
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date Mismatch Between Preview and Print (Access 2000)

    The same thing.

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date Mismatch Between Preview and Print (Access 2000)

    Try this, then:

    Perhaps your report has problems reading the values of ActiveX controls.
    Place two text boxes on the form, named txtFromDate and txtToDate.
    Set their control source to =[acxFromDate] and =[acxToDate].
    Leave them visible for the moment, so that you can see whether they contain the correct dates.
    Replace acxFromDate and acxToDate in the control source of the text box on the report by txtFromDate and txtToDate.
    If it works, make txtFromDate and txtToDate invisible and check that the report still prints correctly.

    Otherwise, I have no idea (I did a test on my PC, values from an ActiveX control on a form printed OK on a report) <img src=/S/shrug.gif border=0 alt=shrug width=39 height=15>

  5. #5
    2 Star Lounger
    Join Date
    Mar 2001
    Location
    Colorado, USA
    Posts
    144
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date Mismatch Between Preview and Print (Access 2000)

    That was the problem. I was preparing to test this approach when I received your response. It's certainly puzzling why it wouldn't work with the ActiveX controls.

    Thanks for the help.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •