Export (0) Print
Expand All
MFC
Expand Minimize

COleClientItem::CreateFromData

Call this function to create an embedded item from a COleDataObject object.

BOOL CreateFromData( 
   COleDataObject* pDataObject, 
   OLERENDER render = OLERENDER_DRAW, 
   CLIPFORMAT cfFormat = 0, 
   LPFORMATETC lpFormatEtc = NULL  
);

pDataObject

Pointer to the COleDataObject object from which the OLE item is to be created.

render

Flag specifying how the server will render the OLE item. For the possible values, see OLERENDER in the Windows SDK.

cfFormat

Specifies the Clipboard data format to be cached when creating the OLE item.

lpFormatEtc

Pointer to a FORMATETC structure used if render is OLERENDER_FORMAT or OLERENDER_DRAW. Provide a value for this parameter only if you want to specify additional format information beyond the Clipboard format specified by cfFormat. If you omit this parameter, default values are used for the other fields in the FORMATETC structure.

Nonzero if successful; otherwise 0.

Data transfer operations, such as pasting from the Clipboard or drag-and-drop operations, provide COleDataObject objects containing the information offered by a server application. It is usually used in your override of CView::OnDrop.

For more information, see OleCreateFromData, OLERENDER, and FORMATETC in the Windows SDK.

Header: afxole.h

Community Additions

ADD
Show:
© 2014 Microsoft