Print report directly

mafhobb

Registered User.
Local time
Today, 06:10
Joined
Feb 28, 2006
Messages
1,249
Ok, so this code on an "on click" event opens up the report I want to print:
Code:
DoCmd.OpenReport "Large Label", acViewPreview

But..what if I did not want any preview and I just want the report to print without any other windows dialog opening up on this same "on click" event?

mafhobb
 
This methods syntax is:

expression.OpenReport(ReportName, View, FilterName, WhereCondition, WindowMode, OpenArgs)


Use acViewNormal as the View argument.
 
The way that I deal with this type of thing is to provide users with options for what output they want for their report. I place an Opton Group control on my form and include options like: Preview Report, Send to Printer, Export to Excel and Create PDF.

Then in a Coommand button's Click Event I use a Select Case statement to determine what code to execute.
 
Mr B. I like your aproach.

Isskint, thank you!

mafhobb
 

Users who are viewing this thread

Back
Top Bottom