Print vs Preview

G

Guest

my form has a button to preview my report before printing it. The button's
OnClick code is
Dim strDocName As String
strDocName = "rptResultsByRegion"
DoCmd.OpenReport strDocName, acPreview

Now, depending on a number of factors, I'll want to print out anywhere from
0 to 5 copies, the usual being 2. I currently do this by clicking <ctrl>P
and selecting the number.

Is there a nicer way to do this, say a popup where I can enter the number of
copies? When the popup is closed by hitting, say, cmdPrint, the preview
should close as well and the reports should print. I don't know enough about
code yet to get this to work.

I appreciate any assistance
 
A

Allen Browne

You can use the Printout action (in a macro) or method (in code) to specify
the number of pages.
 

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