BCGControlBar Pro for MFC
virtual int CBCGPGridCtrl::OnCalcPrintPages ( CDC *  pDC,
CPrintInfo *  pInfo 
)
virtual

Called by the framework to layout the pages and calculates the number of pages to print.

Returns
The number of pages to print.

This function is called by the framework after CBCGPGridCtrl::OnBeginPrinting and before CBCGPGridCtrl::OnPrint, when the grid has a device context and print page size. The default implementation layouts the page and calls CBCGPGridCtrl::CalcPages to return the count of pages. Override this function and CBCGPGridCtrl::PrintLayout if you need custom page layout when printing.

Parameters
pDCA pointer to a printer's device context.
pInfoPoints to a CPrintInfo structure that describes the current print job