Board index » delphi » Get Printer info without doing a BeginDoc?

Get Printer info without doing a BeginDoc?

I need to know some things about the currently selected printer.
Specifically, what you get from GetDeviceCaps with PHYSICALOFFSETX and
PHYSICALOFFSETY. But if I try to use GetDeviceCaps passing
Printer.Canvas.Handle, I get an error unless I do a BeginDoc. But I don't
want to do a BeginDoc, because I'm actually going to preview, not print.

How can I handle this?

-Dan

 

Re:Get Printer info without doing a BeginDoc?


Thanks!

-Dan

Kurt Barthelmess (TeamB) <71333.2...@compuserve.com> wrote in message
<346509c2.3291...@forums.borland.com>...

Quote
>Dan -

>Use Printer.Handle. Until you start printing, the Canvas.Handle
>property is invalid.

>Good luck.

>Kurt

Re:Get Printer info without doing a BeginDoc?


Dan -

Use Printer.Handle. Until you start printing, the Canvas.Handle
property is invalid.

Good luck.

Kurt

Other Threads