COleClientItem::GetExtent

BOOL GetExtent( LPSIZE lpSize, DVASPECT nDrawAspect = (DVASPECT)-1 );

Return Value

Nonzero if successful; 0 if the OLE item is blank.

Parameters

lpSize

Pointer to a SIZE structure or a CSize object that will receive the size information.

nDrawAspect

Specifies the aspect of the OLE item whose bounds are to be retrieved. For possible values, see SetDrawAspect.

Remarks

Call this function to retrieve the OLE item’s size.

If the server application was written using the Microsoft Foundation Class Library, this function causes the OnGetExtent member function of the corresponding COleServerItem object to be called. Note that the retrieved size may differ from the size last set by the SetExtent member function; the size specified by SetExtent is treated as a suggestion. The dimensions are in MM_HIMETRIC units.

Note   Do not call GetExtent during the processing of an OLE handler, such as OnChange. Call GetCachedExtent instead.

For more information, see IOleObject::GetExtent in the OLE documentation.

COleClientItem OverviewClass MembersHierarchy Chart

See Also   COleClientItem::SetExtent, COleClientItem::GetCachedExtent, COleServerItem::OnGetExtent