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


Sets the icon for the file or directory at the specified path.

Component Version macOS Windows Linux Server iOS SDK
QuickLook Files 2.7 ✅ Yes ❌ No ❌ No ✅ Yes, on macOS ❌ No
MBS( "Icon.SetIcon"; Path; image )   More


Parameter Description Example
Path The path to the file or folder. "/Applications"
image A container value with some picture. Can be JPEG, GIF, BMP, PNG or TIFF. $image


Returns OK on success.


Sets the icon for the file or directory at the specified path.
See also App.SetDockIcon to change the app icon.

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.


Sets icon of a file on the desktop:

MBS("Icon.SetIcon"; "/Users/Christian/Desktop/test.pdf"; Data::image)

See also

Release notes

Example Databases

Blog Entries

This function checks for a license.

Created 18th August 2014, last changed 13th November 2023

Icon.GetIconWithQuickLook - ImageCapture.CameraInfo