Printing hard copy of the view
Naomitsu Watanabe / =?ISO-2022-JP?B?GyRCRU9KVUQ+S3 -- n.watanabe@esc.longdist.ntt.co.jp
Wednesday, November 06, 1996
Environment: Win NT 3.51 , VC++ 4.0
Hello,
I am using the draw tools, and trying to print the view (CMyView,
derived from CDrawToolView).
CDrawToolView, derived from CScrollView, has a OnDraw method.
But nothing is printed when I call OnDraw in OnPrint.
If possible, I give up using OnDraw in the OnPrint and try to print
the hard copy of the view.
Does anyone know how to code printing the hard copy of the view?
Thanks.
__
Naomitsu Watanabe
(n.watanabe@esc.longdist.ntt.co.jp)
Jim Lawson Williams -- jimlw@mail.ccur.com.au
Saturday, November 09, 1996
At 05:37 PM 06-11-96 +0900, you wrote:
>Environment: Win NT 3.51 , VC++ 4.0
>
>Hello,
>
>I am using the draw tools, and trying to print the view (CMyView,
>derived from CDrawToolView).
>CDrawToolView, derived from CScrollView, has a OnDraw method.
>But nothing is printed when I call OnDraw in OnPrint.
>If possible, I give up using OnDraw in the OnPrint and try to print
>the hard copy of the view.
>
>Does anyone know how to code printing the hard copy of the view?
>
>Thanks.
>__
>Naomitsu Watanabe
>(n.watanabe@esc.longdist.ntt.co.jp)
>
>
Hmmmm. Assuming you are using a suitable mapping-mode, and that your
coordinate transforms are correct,
then my guess is: no OnPreparePrinting(). From the 4.1 CDROM:
virtual BOOL OnPreparePrinting( CPrintInfo* pInfo );
Return Value
Nonzero to begin printing; 0 if the print job has been canceled.
Parameters
pInfo Points to a CPrintInfo structure that describes the current print job.
Remarks
Called by the framework before a document is printed or previewed. The
default implementation does nothing.
You must override this function to enable printing and print preview. Call
the DoPreparePrinting member ...
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Regards,
Jim LW
| Вернуться в корень Архива
|