Platforms to show: All Mac Windows Linux Cross-Platform

Back to JSContextMBS class.

JSContextMBS.globalObject as JSObjectMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property JavaScript MBS MacFrameworks Plugin 15.4 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Gets the global object of a JavaScript execution context.
Example
Var c as new JSContextMBS

Var v as JSObjectMBS = c.globalObject
Var e as JSValueMBS

v.SetProperty "Hello", c.valueWithString("World"), e
v.SetProperty "Value", c.valueWithDouble(5), e

MsgBox c.globalObject.JSONString

(Read only property)

Some examples using this property:

JSContextMBS.Group as JSContextGroupMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property JavaScript MBS MacFrameworks Plugin 25.5 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Gets the context group to which a JavaScript execution context belongs.

(Read only property)

JSContextMBS.Handle as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property JavaScript MBS MacFrameworks Plugin 15.4 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
The internal object reference.

(Read and Write property)

JSContextMBS.Inspectable as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property JavaScript MBS MacFrameworks Plugin 25.5 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Whether the context is inspectable in Web Inspector.

Default is false.

Requires macos 13.3, ios 16.4 or newer.
(Read and Write property)

JSContextMBS.Name as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
property JavaScript MBS MacFrameworks Plugin 15.4 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
The name.
Example
Var c as new JSContextMBS

c.Name = "Hello"
MsgBox c.Name

Requires Mac OS X 10.10 and newer.
(Read and Write property)

JSContextMBS.Tag as Variant

Type Topic Plugin Version macOS Windows Linux iOS Targets
property JavaScript MBS MacFrameworks Plugin 15.4 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
The tag value.

You can store anything here and as long as the JSContext object exists, this value is kept referenced.
(Read and Write property)

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


The biggest plugin in space...