CHAPTER 6 – Functions and Methods
OMRON
Page 130
Revision 2.0
ExecuteJScript
Description
Creates aliases allowing Java Script to be executed in line. See Appendix C for a list of supported
functions and details of the Windows Scripting Host.
Syntax
@JSCRIPT
@ENDSCRIPT
Typical Examples
@JSCRIPT
Point(“PointName”) = OLE_1.Height;
@ENDSCRIPT
This Java Script will write the value of the property ‘Height’ from the OLE object ‘OLE1’ into the
Point named ‘PointName’.
Note:
The Java Script can not include the { or } characters. To use these, put the script in a
text file and use the ExecuteJScriptFile function.
ExecuteVBScriptFile
Description
Allows Visual Basic script stored in a text file to be executed. This uses the windows scripting host
which must be installed. See chapter 5 for a list of supported functions.
Syntax
returnstate = ExecuteVBScriptFile(scriptfile)
Remarks
Argument
Type
Description
returnstate
bool
1 if the function is successful otherwise 0.
scriptfile
Text
The name of the file with the Visual Basic Script to execute.
Typical Examples
returnstate = ExecuteVBScriptFile(“c:\vbscript.txt”)
This will execute the Visual Basic Script stored in “c:\vbscript.txt”.
Summary of Contents for CX-SUPERVISOR - SCRIPT REFERENCE REV2.0
Page 2: ...CX Supervisor Script Language Software Revision 2 0...
Page 3: ......
Page 5: ...CX Supervisor Script Language OMRON Page ii Revision 2 0...
Page 7: ...CX Supervisor Script Language OMRON Page iv Revision 2 0...
Page 9: ...CX Supervisor Script Language OMRON Page vi Revision 2 0...
Page 13: ......
Page 15: ...CHAPTER 1 Introduction OMRON Page 2 Revision 2 0...
Page 19: ...CHAPTER 2 Expressions OMRON Page 6 Revision 2 0...
Page 21: ...CHAPTER 3 Scripts OMRON Page 8 Revision 2 0...
Page 151: ...CHAPTER 8 Colour Palette OMRON Page 138 Revision 2 0...