Provides the management of the Javascript/native code cross-calls. Its only instance MobileCRM.bridge is created immediately after the "JSBridge.js" script is loaded.
Property |
Type |
Description |
platform |
String |
A string identifying the device platform (e.g. Android, iOS, Windows, WindowsRT, Windows10 or WindowsPhone). |
version |
Number |
A number identifying the version of the JSBridge. This is the version of the script which might not match the version of the application part of the bridge implementation. Application version must be equal or higher than the script version. |
Method |
Description |
alert |
Shows a message asynchronously and calls the callback after it is closed by user. |
closeForm |
Closes a form containing this HTML document. |
enableDebug |
Enables platform-specific features for debugging the web page. |
enableZoom |
Enables platform-specific pinch zoom gesture. |
getWindowSize |
[v8.0] Returns the size of the window in logical pixels without any scaling and viewport calculations.. |
invokeCommandPromise |
|
invokeMethodPromise |
Invokes a method on exposed managed object asynchronously as a Promise. |
invokeStaticMethodPromise |
Invokes a static method on specified type asynchronously as a Promise. |
log |
[v8.0] Appends a message into the JSBridge log. |
onGlobalEvent |
[v9.0] Binds or unbinds the handler for global event. |
raiseGlobalEvent |
[v9.0] Raises the global event which can have listeners bound by other iFrames. |