1 report many headings

A

Afrosheen

Right now I have 4 reports but the information in it is the same. Ex: A-Days,
A-Nights, B-Days, & B-Nights. Like I said all the information within it is
the same. Just the header is different.

What I'd like to do is use one report when I click on the command button
"A-Days" then the string "A-Days" would be passed to the report and be
printed. The same with all the reports. The reports are being generated by a
query of the same names above.
 
M

Marshall Barton

Afrosheen said:
Right now I have 4 reports but the information in it is the same. Ex: A-Days,
A-Nights, B-Days, & B-Nights. Like I said all the information within it is
the same. Just the header is different.

What I'd like to do is use one report when I click on the command button
"A-Days" then the string "A-Days" would be passed to the report and be
printed. The same with all the reports. The reports are being generated by a
query of the same names above.


Sounds like all you need is for the command buttond code to
use the OpenReport method's OpenArgs argument:
DoCmd.OpenReport stDoc, OpenArgs:= "A-Days"
Then the report's Open event can set a label's caption:
Me.somelabel.Caption = Me.OpenArgs
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top