Click or drag to resize

ImageFormatInfo Class

Holds the information for exporting an image in the specified format.
Inheritance Hierarchy

Namespace:  Easymap.AddIn.Export
Assembly:  EasyMap.AddIn (in EasyMap.AddIn.dll) Version: 12.0.0.0
Syntax
public abstract class ImageFormatInfo : BaseObject

The ImageFormatInfo type exposes the following members.

Properties
  NameDescription
Public propertyExportRoot
The object which will be exported.
Public propertyFilename
The filename of the exported image
Public propertyImageDPI
The DPI is used to calculate the size of the image in centimeter/inch. 72 dpi or 96 dpi is the screen resolution.
Public propertyImageFormat
The image format used for the export
Public propertyImageHeight
Height of the image in pixel. The width is calculated to preserve the aspect ratio.
Top
Remarks
This class holds all information necessary to export an image. Use the CreateImageFormatInfo(ImageFormat) function to create an actual ImageFormatInfo such as an PNGImageFormatInfo or EMFImageFormatInfo. The ExportRoot is used to specify the object to export. Use ImageHeight to specify the height of the image in pixel. ImageDPI is used to define the dimensions in centimeter/inch.
Examples
Export the current sheet as an PNG-Image (C#)
C#
var info = app.CurrentDocument.Export.CreateImageFormatInfo(ImageFormat.PNG);

info.ExportRoot = app.CurrentDocument.CurrentSheet;
info.ImageHeight = 1500;
info.Filename = "c:\\image.png";

app.CurrentDocument.Export.ExportImage(info);
Export the current view as an PNG-Image (VBS)
VBScript
set app = CreateObject("EasyMap.Application")
set doc = app.CurrentDocument

set info = doc.Export.CreateImageFormatInfo(ImageFormat_PNG)

set info.ExportRoot = doc.CurrentSheet.Window
info.ImageHeight = 1500
info.Filename = "c:\image.png"

doc.Export.ExportImage(info)
See Also
Inheritance Hierarchy
SystemObject
  SystemMarshalByRefObject
    System.Runtime.InteropServicesStandardOleMarshalObject
      BaseObject
        Easymap.AddIn.ExportImageFormatInfo
          Easymap.AddIn.ExportBMPImageFormatInfo
          Easymap.AddIn.ExportEMFImageFormatInfo
          Easymap.AddIn.ExportEMFPlusImageFormatInfo
          Easymap.AddIn.ExportGeoTIFImageFormatInfo
          Easymap.AddIn.ExportJPGImageFormatInfo
          Easymap.AddIn.ExportMapExtractImageFormatInfo
          Easymap.AddIn.ExportPDFImageFormatInfo
          Easymap.AddIn.ExportPNGImageFormatInfo
          Easymap.AddIn.ExportTIFImageFormatInfo
          Easymap.AddIn.ExportTileImageFormatInfo
          Easymap.AddIn.ExportXPSImageFormatInfo