Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic


Gets the handle of the enhanced metafile, previously set with SetEnhMetafile, that is associated with CStatic.

HENHMETAFILE GetEnhMetaFile( ) const;

A handle to the current enhanced metafile, or NULL if no enhanced metafile has been set.

CStatic myStatic;

// Create a child enhanced metafile static control.
myStatic.Create(_T("my static"), 
   CRect(10,10,150,50), pParentWnd);

// If no image is defined for the static control, define the image 
// to be "myemf.emf."
if (myStatic.GetEnhMetaFile() == NULL)
   myStatic.SetEnhMetaFile( ::GetEnhMetaFile(_T("myemf.emf")) );
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2014 Microsoft. All rights reserved.