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:
9.3
9.4
9.5
10.0
10.1
10.2
10.3
10.4
10.5
10.6
Statistic
FMM
Blog
JS.Release
Frees the JavaScript engine.
| Component | Version | macOS | Windows | Linux | Server | FileMaker iOS SDK |
| JavaScript | 10.0 | Yes | Yes | Yes | Yes | Yes |
(old name: JS.Free)
Parameters
| Parameter | Description | Example |
|---|---|---|
| JSRef | The JavaScript reference number. | $js |
Result
Returns OK or error.
Description
Frees the JavaScript engine.Examples
Evaluate some expressions:
Set Variable [ $js ; Value: MBS( "JS.New" ) ]
Set Variable [ $r ; Value: MBS( "JS.Evaluate"; $js; "4+5") ]
Show Custom Dialog [ "Result" ; $r ]
Set Variable [ $r ; Value: MBS( "JS.SetGlobalProperty"; $JS; "test"; "\"Hello World\"" ) ]
Set Variable [ $r ; Value: MBS( "JS.Evaluate"; $js; "test + test;") ]
Show Custom Dialog [ "Result" ; $r ]
Set Variable [ $r ; Value: MBS( "JS.Release"; $JS ) ]
Cleanup script:
If [ Length($$js) > 0 ]
Set Variable [ $r ; Value: MBS( "JS.Release"; $$js ) ]
Set Variable [ $$js ; Value: "" ]
End If
See also
- JS.AddFileMakerEvaluateFunction
- JS.AddFileMakerSQLFunction
- JS.AddFunction
- JS.CallFunction
- JS.EvaluateToString
- JS.New
- JS.SetGlobalProperty
- JS.TimeToUTCDate
- JSON.Release
- SSH.Release
Blog Entries
Release notes
- Version 10.5
- Added AVExport.ReleaseAll, AVRecorder.ReleaseAll, CoreML.ReleaseAll, DNSLookup.ReleaseAll, Dictionary.ReleaseAll, FM.SQL.ReleaseAll, JS.ReleaseAll, JavaScript.ReleaseAll, LDAP.ReleaseAll, PDFKit.ReleaseAll, PKCS12.ReleaseAll, PKCS7.ReleaseAll, PKey.ReleaseAll, SSH.ReleaseAll, WinSendMail.ReleaseAll, WindowsML.ReleaseAll, WordFile.ReleaseAll, and X509.ReleaseAll.
- Renamed JS.Free to JS.Release for consistency. Old name stays valid.
Created 7th December 2019, last changed 29th October 2020
JS.ObjectCount - JS.ReleaseAll
Feedback: Report problem or ask question.
Links
MBS Xojo blog