Printing a form (Continuation)

A

Amateur

I have the following cde for my button:
*******************
Private Sub preview_Click()
Call Shell("""C:\Program Files\Microsoft Office\OFFICE11\MSACCESS.EXE""
""C:\cps208\sales.mdb""/Xpreviewcommission ", 1)
End Sub
********************
I created a Macro in the "sales.mdb" - Echo, setwarnings,OpenReport,Quit.
OpenReport I put in Preview mode.
If I push my command button the Db "sales" comes up - is doing nothing - and
close again.
What am I doing wrong? I just would like to see a preview from the report
before printing.

Thanks
Klaus
 

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

Similar Threads


Top