Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
JavaScript.RegisterRunScriptFunction
Registers a run script function.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
JavaScriptWebKit | 5.4 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
MBS( "JavaScript.RegisterRunScriptFunction"; JavaScriptContext; FunctionName ) More
Parameters
Parameter | Description | Example |
---|---|---|
JavaScriptContext | The reference number of the javascript context. | $Context |
FunctionName | The name for the new function. | "StartScript" |
Result
Returns OK or error.
Description
Registers a run script function.The javascript function takes first parameter the filename, second parameter the script name. Optionally third parameter is passed as text to the script.
Call for example like this: FMRunScript('Javascript.fp7', 'test', 'Hello World')
Examples
Register RunScript function:
Set Variable [$r; Value:MBS( "JavaScript.RegisterRunScriptFunction"; $$Context; "FMRunScript" )]
# later:
# FMRunScript('Javascript.fp7', 'test', 'Hello World')
See also
Example Databases
Blog Entries
This function checks for a license.
Created 7th November 2015, last changed 9th February 2023
JavaScript.RegisterFunction - JavaScript.RegisterSQLQueryFunction