Results 1 to 5 of 5
  1. #1
    5 Star Lounger
    Join Date
    Nov 2001
    Location
    Jerusalem, Israel
    Posts
    708
    Thanks
    0
    Thanked 1 Time in 1 Post

    On Format (XP/2K)

    I have a report which is actually a receipt. One of the fields in the underlying table is whether this is the original receipt or a copy. I would like to put in the On Print event a way to step through the underlying recordset of the report (which is always filtered) and if that field is not set to true (that this is a copy), after it is printed it should then be changed to true.
    Can I set a recordset object to the underlying recordset of the report and then modify that recordset in the On Print event. I have tried different approaches and nothing seems to work.
    Thanks

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: On Format (XP/2K)

    Instead of what you're trying to do, make the report a two page report, with the same controls on each page but a different label to show whether it is the original or copy.
    Charlotte

  3. #3
    5 Star Lounger
    Join Date
    Nov 2001
    Location
    Jerusalem, Israel
    Posts
    708
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: On Format (XP/2K)

    But sometimes people lose the original and want a copy, and based on the Tax laws it has to be clear that it is a copy and not the original.
    Thanks

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

    Re: On Format (XP/2K)

    I think it would be inefficient to do this for every record separately. You could perhaps use the Recordset property of the report in the On Format or On Print event of the report footer section. Note that Access doesn't distinguish between previewing a report and printing it out.
    Alternatively, you could create an update query with the same filter as the report, and run this after the report has been viewed/printed.

  5. #5
    5 Star Lounger
    Join Date
    Nov 2001
    Location
    Jerusalem, Israel
    Posts
    708
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: On Format (XP/2K)

    thanks

Posting Permissions

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