|Examples||Mac & Win||Server||Client||Guides||Statistic||FMM||Blog||Deprecated||Old|
Queries bounding rectangle from EMF file.
|DynaPDF||7.3||❌ No||✅ Yes||❌ No||✅ Yes, on Windows||❌ No|
|The PDF reference returned from DynaPDF.New.|
|Filename||The native file path to the EMF file.||"C:\test.wmf"|
Returns rectangle or error.
DescriptionQueries bounding rectangle from EMF file.
Retrieves the logical bounding box of an enhanced or Windows metafile. The parameter FileName must be the file path to the EMF or WMF file. Returns the unscaled logical bounding box of the metafile. This bounding box is required to calculate a user defined cutting area or viewport (see the example below the description of the function).
Two WMF formats are available, the old non-portable WMF format and the newer portable WMF format. Both formats must be converted to EMF with the GDI function SetWinMetaFileBits() before the logical bounding box can be calculated (the conversion is done automatically). However, non- portable WMF files are device-dependent, they contain no size information. To get correct results, the default size must be set with the function DynaPDF.SetWMFDefExtent beforehand. The parameters Width and Height are passed to the member xExt, yExt of the structure METAFILEPICT which is required to convert WMF files to EMF. The default size is 0, 0, that means the GDI calculates the size automatically but mostly incorrect.
Because the GDI function SetWinMeatFileBits() is used to convert WMF files to EMF, WMF files are not supported under Linux or UNIX.
This function requires a native path. Use Path.FileMakerPathToNativePath to convert a FileMaker path to a native path if required. If you like to have the user choose the path, you can use FileDialog functions.
For Server be aware that server has limited permissions and may not be able to access all files on a computer.
See also GetLogMetafileSize function in DynaPDF manual.
This function checks for a license.
Created 18th May 2017, last changed 18th May 2017