Solved

Force to print report on single side in access

Posted on 2010-08-18
7
818 Views
Last Modified: 2013-11-28

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?
0
Comment
Question by:tvae
  • 3
  • 3
7 Comments
 
LVL 84
ID: 33465818
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
0
 

Author Comment

by:tvae
ID: 33465927
Yes using access 2002. The printer is set to single but dont know why it's printing double sided
0
 

Author Comment

by:tvae
ID: 33466343
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
0
Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 500 total points
ID: 33466712
Another Long shot...

1. Open the Report in design View
2. Make a small change to the design of the report (move a control a little)
3. Go into Page Setup and manually change the printer properties to print Single sided.
4. Save the Report.
5. Run the Compact and Repair Utility
6. Test the report.

The theory behind this is, by changing the report slightly, then saving the report that this will "Force" the printer settings to be saved with the report.

This worked for a prior question, I guess it is worth a shot here.

Like LSM, I have seen the code to do this, but he can probably dig it up for 2002 access db files...

;-)

JeffCoachman
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 33466725
^ oh and if you ty this, use the simple code to open the report:
    DoCmd.OpenReport "reportname", acViewNormal
0
 

Author Closing Comment

by:tvae
ID: 33467107
omg..that was it.
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 33467685
;-)
0

Featured Post

Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question