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

Preview.Create

Creates a new preview area inside the window with the given rectangle.

Component Version macOS Windows Linux Server iOS SDK
Preview 13.3 ✅ Yes ✅ Yes ❌ No ❌ No ❌ No
MBS( "Preview.Create"; WindowRef; x; y; w; h { ; DX; DY; classID } )   More

Parameters

Parameter Description Example Flags
WindowRef Window Reference is the unique OS level window ID. You can obtain this by using the Window.FindByTitle or Window.FindByIndex functions. Pass zero to access the frontmost window. 0
x The left coordinate in the window. 0
y The top coordinate in the window. 0
w The width of the preview area in the window. 600
h The height of the preview area in the window. 400
DX Available in MBS FileMaker Plugin 14.3 or newer.
A delta to move drop area more to left or right.
0 Optional
DY Available in MBS FileMaker Plugin 14.3 or newer.
A delta to move drop area more to top or bottom.
0 Optional
classID Available in MBS FileMaker Plugin 14.3 or newer.
The class UUID for the preview handler to use.
Optional

Result

Returns reference number or error.

Description

Creates a new preview area inside the window with the given rectangle.
A way to display a PDF Viewer in FileMaker independent of an interactive container.
Available on Windows 10 and newer.

If you use a register on the window, be aware that the drop area actually is in front of the register. So you need to check in the script which register page is current and should get the dropped files.

Use Preview.Release later to destroy the preview area.
Preview reference numbers are starting at 92000 and counting up for each new preview area.

See HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\PreviewHandlers in the registry for available preview handlers for Windows beside PDF Viewer one.

See also

Release notes

  • Version 14.3
    • Added DX, DY and ClassID parameters to Preview.CreateWithControl and Preview.Create functions.

Blog Entries

This function checks for a license.

Created 12nd June 2023, last changed 3th June 2024


Preview.Available - Preview.CreateWithControl