Link to home
Start Free TrialLog in
Avatar of jan_l_keersmaekers
jan_l_keersmaekers

asked on

How to change printer of report in visual basic ?

Hi,

Who knows how i can change the printer in visual basic and also how to get a list of installed printers.

My problem is that when printing on different printers (of the same type) the report seems to forget the papersize and the paperfeeder.
Not on my pc but when i install it on a pc of a user who uses another printer (but same type).

I have som reports printing on B5 and some on A4, A5 from the envelopetray and A4 from tray 1. But when the user adds a new printer the settings in the reports are set to the defaults (A4 and auto).

The user prints on different printers, using different applications, and i would like to select the printer automatically in my access application. So the user doesn't have the change his default printer every time he starts my application.
Avatar of jan_l_keersmaekers
jan_l_keersmaekers

ASKER

Can i change the default printer using code in ms access 97.

In visual basic
dim x as printer
for x=1 to printers
set x....

But how can i do this in MS Access ?
Check out question 10115162. It covers the same topic you are asking about.

Good Luck,
Believer
How do i find question 10115162 ?
Well, that's a good question.  I hear the experts referencing questions by number, but I get skunked when I try to search for a question by number.  Maybe you can only search by keywords. Maybe another expert will tell us how to find a question by using the number.

Try Printer, or default ???

Believer
P.S.

The search option is at each topic level.
ASKER CERTIFIED SOLUTION
Avatar of believer
believer
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
Yes,  when i was looking a the screen i suddenly found it.
Happy Holydays