
Signature
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
> Hi Tonya,
>
[quoted text clipped - 52 lines]
> might be that in your case you need this in order to bully the printer into
> getting the combination or orientation and duplex that you want.
Thanks Jonathan,
I'll give it a try when I get to work.

Signature
Tonya Marshall
> Hi Tonya,
>
[quoted text clipped - 34 lines]
> normally copes with this unassisted by means of setting the orientation in
> the Page Setup dialog. Try adding the following code to the printing module
I have 3 modules in the Duplex template
Printer - do the 2 public subs go in here? It's the macro that starts,
Option Explicit
Booklet - Set orientation1 in here?
Tablet - Set orientation2 in here?
> Public Sub SetOrientation(iOrient As Long)
> SetPrinterProperty DM_ORIENTATION, iOrient
> End Sub
Is this the one that turns the pages 180°?
> Public Function GetOrientation() As Long
> GetColorMode = GetPrinterProperty(DM_ORIENTATION)
> End Function
It's not a color printer.
> You can set the orientation like this
>
> SetOrientation 1 ' sets portrait layout
I expect the above is for booklet layout?
> SetOrientation 2 ' sets landscape layout
Landscape would turn the pages 90°, not 180°
I didn't want landscape, I wanted horizontal binding on a portrait layout
> Normally, setting this property is over-ridden by the Page Setup settings in
> Word (which is why I didn't include it in the original article), but it
> might be that in your case you need this in order to bully the printer into
> getting the combination or orientation and duplex that you want.

Signature
Tonya Marshall
Jonathan West - 23 Nov 2004 11:36 GMT
Hi Tonya,
before we go any further with this, it is possible to go into the Printer
properties dialog and set the duaplxing manually to the way you want it? If
not, then all the messing about with code will not achieve what you are
trying to do.

Signature
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Tonya Marshall - 23 Nov 2004 12:33 GMT
> Hi Tonya,
>
> before we go any further with this, it is possible to go into the Printer
> properties dialog and set the duaplxing manually to the way you want it? If
> not, then all the messing about with code will not achieve what you are
> trying to do.
Yes. I think I mentioned that in my first post.
I can set it for both horizontal and vertical binding, then I can set it
to turn the pages 180 degrees if I need to. (That's what I do when I use
the paper drawer with the 5-hole punched paper so that the holes are at
the top of the page when it's printed.

Signature
Tonya Marshall
Tonya Marshall - 23 Nov 2004 15:10 GMT
Here is an image of the printer properties. Don't know if it will be
helpful or not but thought I'd stick it in:
http://img91.exs.cx/my.php?loc=img91&image=image101.jpg
Jonathan West - 23 Nov 2004 20:54 GMT
> Here is an image of the printer properties. Don't know if it will be
> helpful or not but thought I'd stick it in:
> http://img91.exs.cx/my.php?loc=img91&image=image101.jpg
That 180 degree flip is not part of the standard printer API in Windows.
That means that if you want programmatic access to that feature, you'll have
to contact HP and ask about the API. I'm not all that optimistic of your
chances of getting anywhere with them.
I suspect that the only way to handle this in code may be to define two
copies of the pronter with different names, but both pointing to the same
physcial device. Configure one as duples with the settings you want, and the
other as non-duplex. Then set the ActivePrinter property to one or the other
for the printing you want.

Signature
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup
Tonya Marshall - 24 Nov 2004 00:27 GMT
>> Here is an image of the printer properties. Don't know if it will be
>> helpful or not but thought I'd stick it in:
[quoted text clipped - 10 lines]
> other as non-duplex. Then set the ActivePrinter property to one or the other
> for the printing you want.
Thanks, Jonathan. I appreciate the time you've spent on this. I can't
set the active printer property to something different as we get forms
printed from the AS400 and the standard print configuration is the one
they start from. I know they have control of the printer because what we
receive is printed correctly from the 5-hole punched paper drawer. Maybe
I could ask them what they do/use to make the configurations work.

Signature
Tonya Marshall
Tonya Marshall - 28 Nov 2004 12:18 GMT
>> Here is an image of the printer properties. Don't know if it will be
>> helpful or not but thought I'd stick it in:
[quoted text clipped - 10 lines]
> other as non-duplex. Then set the ActivePrinter property to one or the other
> for the printing you want.
Since that is not going to be possible, I can put a Quick Set Tablet
and Booklet feature with pages turned 180 degrees. What would be useful
would be a macro to return the printer to the default setting so we
don't have to go in and turn the feature off. I fear most would forget
as I have from time to time.
Thanks.

Signature
Tonya Marshall