Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
9.3
9.4
9.5
10.0
10.1
10.2
10.3
10.4
10.5
10.6
Statistic
FMM
Blog
WebView.InstallCallback
Installs JavaScript callback into web viewer.
| Component | Version | macOS | Windows | Linux | Server | FileMaker iOS SDK |
| WebView | 1.3 | Yes | Yes | No | No | No |
MBS( "WebView.InstallCallback" ) More
Parameters
none
Description
Installs JavaScript callback into web viewer.This function needs to be called one time to enable JavaScript to reach out from the web viewer to run a FileMaker Script.
One strategy is to call this function on start-up before any WebViewers have been displayed.
To call back from Javascript to FileMaker, you assign a string to the window.status property:
window.status="Filename:Scriptname"
or
window.status="Filename:Scriptname:Parameter"
The Parameter part can contain ":". Filename must include file extensions so FileMaker finds the database file.
You can also call it within a link with "javascript:window.status='Filename:Scriptname:Parameter'". Like this: href="javascript:window.status='callbacks.fp7:Another Script:Hello World'".
Does not work currently with Internet Explorer 10 on Windows.
Not supported for WebKit 2.x (FileMaker 16 Mac), but works in FileMaker 16, when using a Web Viewer created using WebView.Create.
For FileMaker 16, please check WebView.AddScriptMessageHandler function as a replacement.
Examples
Install Callbacks
MBS("WebView.InstallCallback")
See also
Example Databases
- WebViewer/Javascript calls Filemaker Script/Callbacks with Custom Webviewer
- WebViewer/Javascript calls Filemaker Script/callbacks
- WebViewer/Switch Control/Switch
- Window/Window Scrollbar Position
Blog Entries
- Check out options for FileMaker JavaScript Integration
- FileMaker and WebViewer communication
- Trigger FileMaker Scripts from JavaScript in FileMaker 16
- MBS FileMaker Plugin, version 7.5pr2
- The Internet Explorer 10 Problem
- Using a HTML slider in Filemaker with Webviewer and our plugin
Release notes
- Version 7.5
- Changed WebView.InstallCallback to work in FMP 16 with WebView.Create.
Created 18th August 2014, last changed 31st July 2019
WebView.HasOnlySecureContent - WebView.InstallMultiFileOpenDialog
Feedback: Report problem or ask question.
Links
MBS FileMaker Plugins