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

Rotate printer output

Status
Not open for further replies.

Unscruffed

Programmer
Apr 2, 2002
102
0
16
AU
I'm writing a program that prints reports containing info broken up into many differnt tables. Some of the tables need to be printed in "Landscape" mode, therefore I'm switching between portrait and landscape for each page as necessary. The problem I have is that the lanscape pages print so that the "top" is at the right side of the page (looking at it in potrait style) and it should be at the left.

I'm using standard VB commands (Print, Line, etc) to draw to the printer. My question is: how can I rotate the individual landscape pages by 180 degrees so that they print correctly?

For a visual explaination of the problem see the attachment below. (Html page, 3 x gifs.)

Cheers,
Scruff.

Be good. If you can't, don't get caught!
 
Sorry for the delay replying. I don't use Office at all. I need to rotate what I'm sending to the printer in VB6.

Wondering can this be done using Printer.hDC maybe?

Be good. If you can't, don't get caught!
 
Can it be done using the Printer.hDC? But of course ...
 
Hi strongm, good to hear from again. Hope you are doing well.

I'm not sure how to utilize the printers hdc. If I BitBlt from the printer to a picturebox, I get nothing.

If I draw to a picturebox first, then rotate and BitBlt to the printer, I loose the Anti-Aliasing because of the picturebox, and the output is diminished.

Any idea what to try next?

Be good. If you can't, don't get caught!
 
>If I BitBlt from the printer to a picturebox

Er ... not sure I understand why would you do this?

>I get nothing

Which suggests that you are doing something wrong ... even if it is something a simple as trying to blit a blank page ...

>If I draw to a picturebox first, then rotate

How are you doing the rotation?

>I loose the Anti-Aliasing

What anti-aliasing? You have not previously mentioned antialiasing. You said yo were drawing using VB's Print, Line, etc commands; VB doesn't do antialiasing for these, so I am confused as to what you are talking about.

>Any idea what to try next?

Sure, but I'd like to see some answers to the above before I let you in on the method ...

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top