Exports the sketch to an EMF file.

Usage

Send_Message(OLECtrlEntID, "OLE.MakeMetafile", FilePath, SupportPDF)

Parameters

ParameterDescription
FilePathThe path and filename of the metafile to be created
SupportPDFA flag indicating that the metafile needs to work in a PDF

Remarks

The MakeMetaFile method exports the sketch to an EMF image. Metafiles are vector images, as opposed to raster images like bitmaps. Vector images scale to the current resolution of the device and can be very useful when printing.

Unfortunately, metafiles don't play nicely within PDFs unless each of the objects have backgrounds. If you plan to embed the metafile in a PDF, then you need to set the SupportPDF parameter to 1. The result of giving all sketch objects backgrounds preserves aspect ratio within a PDF at the expense of objects blocking other objects. Thus, it's best to set the SupportPDF parameter to 0 whenever possible.

Example

// Export a metafile
Send_Message(@Window:".OLE_SKETCH", "OLE.MakeMetaFile", "Sketch.emf", 0)

// Export a metafile supporting PDF
Send_Message(@Window:".OLE_SKETCH", "OLE.MakeMetaFile", "SketchForPDF.emf", 1)

See Also

MakeBitmap