Requery, I think.

sdawson

Registered User.
Local time
Today, 15:56
Joined
Apr 22, 2003
Messages
165
I have a continuous form with a tickbox to select records. A command button then kicks off a print routine to print the selected records. Well, all but the last one selected!
I suspect I need to requery the form's query (or maybe the report query) to capture the last record selected.
I have never got to grips with Docmd.Requery.
Is this my answer?
How do I write the code and which event procedure sould it be on?

Thanks for looking.
 
Last edited:
I don't know if this would work, but the command to requery the form would be simply:

me.requery

Place it it in the event on click for the command button before its opens the report to be printed.
 
It does.
Think it's my headcold that's addling me.

Thanks
 
DoCmd.RunCommand acCmdSaveRecord

or

If Me.Dirty Then Me.Dirty = False

on the button before running the report would also have worked. The problem, I think, is that you hadn't saved the last record at the point that you were printing.
 

Users who are viewing this thread

Back
Top Bottom