Export (0) Print
Expand All
Expand Minimize

COleClientItem::SetPrintDevice

Call this function to change the print-target device for this item.

BOOL SetPrintDevice( 
   const DVTARGETDEVICE* ptd  
); 
BOOL SetPrintDevice( 
   const PRINTDLG* ppd  
);

ptd

Pointer to a DVTARGETDEVICE data structure, which contains information about the new print-target device. Can be NULL.

ppd

Pointer to a PRINTDLG data structure, which contains information about the new print-target device. Can be NULL.

Nonzero if the function was successful; otherwise 0.

This function updates the print-target device for the item but does not refresh the presentation cache. To update the presentation cache for an item, call UpdateLink.

The arguments to this function contain information that the OLE system uses to identify the target device. The PRINTDLG structure contains information that Windows uses to initialize the common Print dialog box. After the user closes the dialog box, Windows returns information about the user's selections in this structure. The m_pd member of a CPrintDialog object is a PRINTDLG structure.

For more information about this structure, see PRINTDLG in the Windows SDK.

For more information, see DVTARGETDEVICE in the Windows SDK.

Header: afxole.h

Show:
© 2015 Microsoft