Поделиться через


COleControl::OnSetData

Called by the framework to replace the control's data with the specified data.

virtual BOOL OnSetData( 
      LPFORMATETC lpFormatEtc, 
      LPSTGMEDIUM lpStgMedium, 
      BOOL bRelease 
);

Параметры

  • lpFormatEtc
    Pointer to a FORMATETC structure specifying the format of the data.

  • lpStgMedium
    Pointer to a STGMEDIUM structure in which the data resides.

  • bRelease
    TRUE if the control should free the storage medium; FALSE if the control should not free the storage medium.

Возвращаемое значение

Nonzero if successful; otherwise 0.

Заметки

If the data is in the persistent property set format, the default implementation modifies the control's state accordingly. Otherwise, the default implementation does nothing. If bRelease is TRUE, then a call to ReleaseStgMedium is made; otherwise not.

Override this function to replace the control's data with the specified data.

For more information, see the FORMATETC and STGMEDIUM structures in the Windows SDK.

Требования

Header: afxctl.h

См. также

Основные понятия

COleControl Class

COleControl Members

Hierarchy Chart

COleControl::DoPropExchange