Results 1 to 2 of 2
2005-11-29, 04:26 #1
- Join Date
- Jun 2005
- Thanked 0 Times in 0 Posts
Printing single/double sided (WordXP)
Most people have set their printer to print double sided.
I am trying to write a macro to print single sided, but put the printer back to double sided (if it was set that way).
The following code (written by someone else) prints as single sided:
Public Sub s_PrintSingleSide()
' to change printing properties from long-side duplex printing to none
If Windows.count = 0 Then End
I don't understand how this works, or how to change the printing back to double sided. Can anyone help?
2005-11-29, 04:41 #2
- Join Date
- Feb 2001
- Silicon Valley, USA
- Thanked 93 Times in 89 Posts
Re: Printing single/double sided (WordXP)
SendKeys emulates you pressing those keys at the keyboard. I believe the % character means "Alt" but I'd have to check the help for SendKeys to be sure. Anyway, by looking at the underlined "accelerator key" shortcuts in the dialogs that are manipulated by the above macro, you should be able to work out how to set single-sided/double-sided setting the other way.
Of course, I must add that SendKeys is not always reliable because it depends on the timing working out just so, and the menus and dialogs being in the right place at the right time. In this case, the keys are being sent to the print dialog, but if there is a delay in opening the dialog, some or all of the keystrokes might get lost...