Topics   All   MacOS (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server   Client   Old   Deprecated   Guides   Examples   Videos
New in version: 12.1   12.2   12.3   12.4   12.5   13.0   13.1   13.2   13.3   13.4    Statistic    FMM    Blog  

JS.ObjectCount

Queries global object counter.

Component Version macOS Windows Linux Server iOS SDK
JavaScript 10.1 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "JS.ObjectCount"; JSRef )   More

Parameters

Parameter Description Example
JSRef The JavaScript reference number. $js

Result

Returns number or error.

Description

Queries global object counter.
A fresh JavaScript engine already has about 400 objects for the built-in functionality.

Examples

Query memory statistics:

Set Variable [ $JS ; Value: MBS( "JS.New" ) ]
Show Custom Dialog [ "JavaScript memory statistics:" ; MBS( "JS.StringCount"; $JS ) & " strings" & ¶ & MBS( "JS.ObjectCount"; $JS ) & " objects" ]

See also

Release notes

Blog Entries

This function checks for a license.

Created 31st January 2020, last changed 19th April 2020


JS.Now - JS.Release

💬 Ask a question or report a problem