Print current Record

  • Thread starter Thread starter db
  • Start date Start date
D

db

I'm trying to create a command button on an Access 2000
form that will allow an end user to open a report, print
the current record then close the report and return to
the form so they may continue their input. I tried
several ways to create a macro using OpenReport however
it either prompts me to enter the field name or it prints
all pages EXCEPT the current record. Either way, I
receive "#Error" in the field and the rest of the report
is blank.
 
db,

You either need to have the report based on a query, which has a
reference in its criteria to the primary key field of the current
record on the form, using syntax such as [Forms]![FormName]![IDName].
Or, you need to use the Where Condition argument of the OpenReport
macro action, which will look a bit like...
[IDField]=[Forms]![FormName]![IDField]

- Steve Schapel, Microsoft Access MVP
 
Back
Top