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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to Change the Default Printer Via Code

Status
Not open for further replies.

fotojock

Programmer
Jun 1, 2000
9
US
I have a Foxpro Win program on my network that prints to a label printer.&nbsp;&nbsp;Each time a job is sent to that printer, a page eject occurs on my Windows DEFAULT printer.&nbsp;&nbsp;I've tried everything to eliminate the eject, but to no avail.<br><br>I wonder if there's a command I could call (or some value I could modify) from inside my program to automatically change the Windows default printer on the fly (invisibly to my operators).&nbsp;&nbsp;If I could, I would switch the default to a dummy printer (LPT3), print my labels, then switch it back, in hopes of eliminating that pesky page eject.&nbsp;&nbsp;Must I modify WIN.INI or some other file on the fly or is there a command that switches the default printer?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top