LoadOptions.ConvertMetafilesToPng

LoadOptions ConvertMetafilesToPng property. Gets or sets whether to convert metafile Wmf or Emf images to Png image format. Default is false.

LoadOptions.ConvertMetafilesToPng property

Gets or sets whether to convert metafile (Wmf or Emf) images to Png image format. Default is false.

public bool ConvertMetafilesToPng { get; set; }

Remarks

Metafiles (Wmf or Emf) is an uncompressed image format and sometimes requires to much RAM to hold and process document. This option allows to convert all metafile images to Png on document loading. Please note - conversion vector graphics to raster decreases quality of the images.

Examples

Shows how to convert WMF/EMF to PNG during loading document.

LoadOptions loadOptions = new LoadOptions();
loadOptions.ConvertMetafilesToPng = true;

Converter.Create()
    .From(MyDir+"SimpleEmf.docx", loadOptions)
    .To(ArtifactsDir + "LoadOptions.ConvertMetafilesToPng.docx")
    .Execute();

See Also