David: I do this another way, I don't know whether you know about this
already, but here goes...
I add preview and print commands to my forms and switchboard. To preview a
report from a form or switchboard, you must first create a query for your
particular table. On the field that you want to preview, which must be unique
(like the autonumber field), type [enter record number]. Save and close.
With your form in design view, click on "label" on toolbar. Place your
cursor on the location of your form that you want this box to be placed.
Next type in description of action, i.e. "Print and preview this record".
Next right click on the box and choose build event. Choose macro. Type the
following on the lines
Echo
Save (must state form you are in below)
Close (choose Form, then name of form you are in)
Open Report (Choose report name and print preview below)
Maximize.
Save as MAcro 1 or whatever you choose to call it.
Now when you open your form,and press this button, a prompt will ask you to
"enter record number". Then you will see you report in preview mode and then
you can print.
Hope this helps.
DavidGuaman said:
Is it possible to add a print command button to a report on "preview view"?
I am able to add a command button but doesn't allow me to add an action. I
know the command button can be added from the form, but I need to preview the
report first and I dont like that I have to go to the file menu to print.
Thanks for your help!
David