Platforms to show: All Mac Windows Linux Cross-Platform

Back to LinuxJavaScriptContextMBS class.

LinuxJavaScriptContextMBS.CheckScriptSyntax(script as string, sourceURL as string = "", StartLineNumber as Integer = 0) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
Checks for syntax errors in a string of JavaScript.

script: A string containing the script to check for syntax errors.
sourceURL: A string containing a URL for the script's source file. This is only used when reporting exceptions. Pass "" if you do not care to include source file information in exceptions.
startingLineNumber: An integer value specifying the script's starting line number in the file located at sourceURL. This is only used when reporting exceptions.
exception: A string in which to store a syntax error exception, if any.
Returns true if the script is syntactically correct, otherwise false.

See also:

LinuxJavaScriptContextMBS.CheckScriptSyntax(script as string, sourceURL as string, StartLineNumber as Integer, byref JSException as string) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
Checks for syntax errors in a string of JavaScript.

script: A string containing the script to check for syntax errors.
sourceURL: A string containing a URL for the script's source file. This is only used when reporting exceptions. Pass "" if you do not care to include source file information in exceptions.
startingLineNumber: An integer value specifying the script's starting line number in the file located at sourceURL. This is only used when reporting exceptions.
exception: A string in which to store a syntax error exception, if any.
Returns true if the script is syntactically correct, otherwise false.

See also:

LinuxJavaScriptContextMBS.Constructor   Private

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
The private constructor.

LinuxJavaScriptContextMBS.Destructor

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
The destructor.

LinuxJavaScriptContextMBS.EvaluateScript(script as string, sourceURL as string = "", StartLineNumber as Integer = 0) as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
Evaluates a string of JavaScript.

script A string containing the script to evaluate.
sourceURL: A string containing a URL for the script's source file. This is only used when reporting exceptions. Pass "" if you do not care to include source file information in exceptions.
startingLineNumber: An integer value specifying the script's starting line number in the file located at sourceURL. This is only used when reporting exceptions.
exception A string in which to store an exception, if any.
Returns the value as string that results from evaluating script, or "" if an exception is thrown.

You can use JavaScriptEngineMBS class to execute JavaScript without HTMLViewer in our own cross platform JavaScript engine.

See also:

LinuxJavaScriptContextMBS.EvaluateScript(script as string, sourceURL as string, StartLineNumber as Integer, byref JSException as string) as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
Evaluates a string of JavaScript.

script A string containing the script to evaluate.
sourceURL: A string containing a URL for the script's source file. This is only used when reporting exceptions. Pass "" if you do not care to include source file information in exceptions.
startingLineNumber: An integer value specifying the script's starting line number in the file located at sourceURL. This is only used when reporting exceptions.
exception A string in which to store an exception, if any.
Returns the value as string that results from evaluating script, or "" if an exception is thrown.

You can use JavaScriptEngineMBS class to execute JavaScript without HTMLViewer in our own cross platform JavaScript engine.

See also:

LinuxJavaScriptContextMBS.GarbageCollect

Type Topic Plugin Version macOS Windows Linux iOS Targets
method HTMLViewer Linux MBS Linux Plugin 13.5 ❌ No ❌ No ✅ Yes ❌ No Desktop only
Performs a JavaScript garbage collection.

You should not need to call this.

The items on this page are in the following plugins: MBS Linux Plugin.


The biggest plugin in space...