Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiuser printing. Selecting printer on click command 1

Status
Not open for further replies.

Phil4tektips

Technical User
Jul 18, 2005
89
GB
My users are spread over a wide area within the company. I have set up a multiuser database which prints out reports on click of a command button. I have the report page setup settings set to default printer.

Unfortuneately the default for almost all the users is a black and white printer (Document printing!) and their other available printer is colour.

They will not change their default printer to the colour one since most printing is done in black and white.

Is there some way in my command button routine to call up the users printers and allow them to make a selection?

Many thanks,

-Phil4tektips-
 
You can use the common dialog control, call the .ShowPrinter method, select the printer, then call docmd.Openreport.
--Jim
 
See difference between the codes below
[tt]
DoCmd.RunCommand acCmdPrint
[/tt]
will bring the print dialog
[tt]
DoCmd.PrintOut
[/tt]
will print directly.

You need to specify the document to print through the code

________________________________________________________________________
Zameer Abdulla
Visit Me
No two children are alike - particularly if one is yours and the other isn't.
 
This is what I have at the moment assigned to a button click:

Private Sub PrintSingleReport_Click()
'MsgBox BuildWhere(Me)
'DoCmd.RunCommand acCmdPrint
DoCmd.OpenReport "Generic Report A4 Portrait - Single Risk", , , BuildWhere(Me)
End Sub

This prints on their default printer. I tried adding the DoCmd.RunCommand acCmdPrint as shown above, in which I could select a printer, but it printed the report I wanted aswell as the form I was using with the button on it.

Any ideas? Thanks all.
-Phil4tektips-
 
And this ?
DoCmd.OpenReport "Generic Report A4 Portrait - Single Risk", acViewPreview, , BuildWhere(Me)
DoEvents
DoCmd.RunCommand acCmdPrint

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top