Link to home
Start Free TrialLog in
Avatar of tvae
tvae

asked on

Force to print report on single side in access


I have a form command button to print a report and even thought the printer seting is single side print it still print duplex when clicking the button. The command is as below.

DoCmd.OpenReport "reportname", acViewNormal

I dont see anywhere why it should print doeble sided, Is there a code to force it as single sided?
Avatar of Scott McDaniel (EE MVE )
Scott McDaniel (EE MVE )
Flag of United States of America image

Duplex is a function of the printer, not Access, While you may be able to control that from code, it can be difficult to do.

What version of Access are you using? Access 2002+ exposes the Printer object, which you may be able to use:

http://msdn.microsoft.com/en-us/library/aa139946(office.10).aspx
Avatar of tvae
tvae

ASKER

Yes using access 2002. The printer is set to single but dont know why it's printing double sided
Avatar of tvae

ASKER

I have added this rule but still print duplex.

    Dim rpt As Report
    Dim prtnew As Printer
    DoCmd.OpenReport ReportName:="rptPickListALLPONumber", View:=acViewNormal
    'stDocName = "rptPickListALLPONumber"
    Set rpt = Reports!rptPickListALLPONumber
    Set prtnew = rpt.Printer
    prtnew.Duplex = acPRDPSimplex
ASKER CERTIFIED SOLUTION
Avatar of Jeffrey Coachman
Jeffrey Coachman
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
^ oh and if you ty this, use the simple code to open the report:
    DoCmd.OpenReport "reportname", acViewNormal
Avatar of tvae

ASKER

omg..that was it.