Error getting tags :
error 404Error getting tags :
error 404 revBrowserCallScript | revDocs | RunRev
Welcome Guest (Log in)
Product Edition
Version
revBrowserCallScript
Basics
Expander triangle
Type
Function
Syntax

revBrowserCallScript(instanceId, functionName [, parameter1, parameter2, ..., parameterN ])

Introduced
3.5
Environment
Desktop
Platform Support
Mac OS X,Windows
Security
Network
Summary
Calls a web script function in the current browser object
Examples

get revBrowserCallScript(sBrowserId, "swapImages")
get revBrowserCallscript(sBrowserId, "displayTable", tHeader, tFooter)

Additional Comments
Expander triangle

Use the revBrowserCallScript function to call a web script function in the context of the current document in the specified browser object.

Parameters

The instanceId is the integer identifier of a browser object

The functionName is the name of the web script function to call

The parameters parameter1 through to parameterN contain the arguments to pass to the function (optional).

Comments

The revBrowserCallScript function currently searches for and calls JScript functions on Windows and JavaScript functions on OS X. If the function is not found or calling it is not successful, then an "error in script" exception is thrown.

Note that the arguments passed to the function are internally treated as NULL-terminated strings. This means that binary data cannot be passed, it must first be encoded somehow. This is typically done using the base64Encode function.

If you want to execute some arbitrary JavaScript, rather than call an existing function, use the revBrowserExecuteScript function instead.

The revBrowserCallScript function will return whatever the function called returned.

Note: For general information on using the browser library, please see the notes in the revBrowserOpen function reference.

User Comments
Expander triangle