Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

DynaPDF.ReadImageResolutionFile

The function retrieves the horizontal and vertical resolution of an image file.

Component Version macOS Windows Linux Server iOS SDK
DynaPDF 15.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "DynaPDF.ReadImageResolutionFile"; PDF; Path { ; Index } )   More

Parameters

Parameter Description Example Flags
PDF The PDF reference returned from DynaPDF.New. $pdf
Path The native path for the image file. "C:\test\test.jpg"
Index The index of the image for multi image files. 1 Optional

Result

Returns the x and y resolution values as text separated by newline character.

Description

The function retrieves the horizontal and vertical resolution of an image file.
The image resolution is a user defined value that can be stored in certain image formats such as Bitmap or TIFF.
The function returns zero values if the image format does not support a resolution record or if no values are stored in the image file, the image resolution is then 72 DPI.

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.

Examples

Read resolution information for a file:

Set Variable [ $resolutions; Value: MBS(“DynaPDF.ReadImageResolutionFile"; $pdf; "/Users/cs/Desktop/täst.png") ]

Example result:
144
144

See also

Release notes

  • Version 15.2
    • Added DynaPDF.ReadImageFormatFile and DynaPDF.ReadImageResolutionFile function to inspect images files on disk.

Blog Entries

This function checks for a license.

Created 21st March 2025, last changed 28th March 2025


DynaPDF.ReadImageResolution - DynaPDF.Rectangle