Udostępnij za pośrednictwem


CView::OnEndPrintPreview

Called by the framework when the user exits print preview mode.

virtual void OnEndPrintPreview(
   CDC* pDC,
   CPrintInfo* pInfo,
   POINT point,
   CPreviewView* pView 
);

Parameters

  • pDC
    Points to the printer device context.

  • pInfo
    Points to a CPrintInfo structure that describes the current print job.

  • point
    Specifies the point on the page that was last displayed in preview mode.

  • pView
    Points to the view object used for previewing.

Remarks

The default implementation of this function calls the OnEndPrinting member function and restores the main frame window to the state it was in before print preview began. Override this function to perform special processing when preview mode is terminated. For example, if you want to maintain the user's position in the document when switching from preview mode to normal display mode, you can scroll to the position described by the point parameter and the m_nCurPage member of the CPrintInfo structure that the pInfo parameter points to.

Always call the base class version of OnEndPrintPreview from your override, typically at the end of the function.

Requirements

Header: afxwin.h

See Also

Reference

CView Class

Hierarchy Chart

CPrintInfo Structure

CView::OnEndPrinting

Other Resources

CView Members