Partager via


CMetaFileDC::CloseEnhanced

Closes an enhanced-metafile device context and returns a handle that identifies an enhanced-format metafile.

HENHMETAFILE CloseEnhanced( );

Return Value

A handle of an enhanced metafile, if successful; otherwise NULL.

Remarks

An application can use the enhanced-metafile handle returned by this function to perform the following tasks:

  • Display a picture stored in an enhanced metafile

  • Create copies of the enhanced metafile

  • Enumerate, edit, or copy individual records in the enhanced metafile

  • Retrieve an optional description of the metafile contents from the enhanced-metafile header

  • Retrieve a copy of the enhanced-metafile header

  • Retrieve a binary copy of the enhanced metafile

  • Enumerate the colors in the optional palette

  • Convert an enhanced-format metafile into a Windows-format metafile

When the application no longer needs the enhanced metafile handle, it should release the handle by calling the Win32 DeleteEnhMetaFile function.

Requirements

Header: afxext.h

See Also

Concepts

CMetaFileDC Class

CMetaFileDC Members

Hierarchy Chart

CDC::PlayMetaFile

CMetaFileDC::CreateEnhanced

DeleteEnhMetaFile