Pinting certain pages of a report

  • Thread starter Wishful Thinker
  • Start date
W

Wishful Thinker

Would someone please give me an idea of what a code would look like
that prints only certain pages of a report, for example pages 7
through 9?

Thanks!
 
S

Steve Schapel

Wishful,

Try this...

Dim StartingPage As Integer
Dim EndingPage As Integer
StartingPage = InputBox("Enter first page number to print")
EndingPage = InputBox("Enter last page number to print")
DoCmd.OpenReport "YourReport", acViewPreview
DoCmd.PrintOut acPages, StartingPage, EndingPage
 

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