It's bad behaviour of an exe to change OS Default Printer.
Instead you need an applikation specific printer
The first idea would be to use simple SYS(1037) to set a printer during apps lifetime.
The next would be to create a default printer that will restore after application start.
This can be done via the additional parameters of SYS(1037). If you have close interest on this I can post a solution.
Agnes
>Hi,
>
>My computer have three printer queues, I want to set the windows default printer in my application.
>I mean not using SET PRINTER TO command.
>I need set the default printer check sign in Start->Printer and Fax.
>
>Please advise.
>
>Derek Yim
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord
Weeks of programming can save you hours of planning.
OffThere is no place like [::1]