CHAPTER 6 – Functions and Methods
OMRON
Page 88
Revision 2.0
Note:
It is advisable to use a RecordId less than 1024 whenever possible, in order to optimise
file access time (records 0 to 1023 are cached).
WriteMessage
Syntax
returnstate = WriteMessage(“filename”, offset, “text”, linefeed)
Remarks
Argument Type
Description
returnstate
bool
Returnstate
is ‘1’ if the function is successful, or ‘0’ otherwise.
filename
string
Pathname of file to be written.
offset
integer
An offset from the beginning of the file (in characters)
indicating where to start writing. If the offset is -1 then the
message is appended to the end of the file.
text
string
The text to be written into the file.
linefeed
bool
A flag to indicate a carriage return and line feed should be
appended.
Typical Example
WriteMessage(“C:\CX-SUPERVISOR\TESTFILE.TXT”, 0, “Hello World”, TRUE)
The text ‘Hello World’ is written at the start of the ‘C:\CX-SUPERVISOR\TESTFILE.TXT’ file and
a carriage return and line feed is appended which moves and subsequent text to the start of the next
line.
Note:
When the text is written into the file it overwrites any existing text that may exist at
this location.
Recipe Commands
DisplayRecipes
Syntax
returnstate = DisplayRecipes()
Remarks
Argument Type
Description
returnstate
bool
Returnstate
is ‘1’ if the function is successful, or ‘0’ otherwise.
Содержание CX-SUPERVISOR - SCRIPT REFERENCE REV2.0
Страница 2: ...CX Supervisor Script Language Software Revision 2 0...
Страница 3: ......
Страница 5: ...CX Supervisor Script Language OMRON Page ii Revision 2 0...
Страница 7: ...CX Supervisor Script Language OMRON Page iv Revision 2 0...
Страница 9: ...CX Supervisor Script Language OMRON Page vi Revision 2 0...
Страница 13: ......
Страница 15: ...CHAPTER 1 Introduction OMRON Page 2 Revision 2 0...
Страница 19: ...CHAPTER 2 Expressions OMRON Page 6 Revision 2 0...
Страница 21: ...CHAPTER 3 Scripts OMRON Page 8 Revision 2 0...
Страница 151: ...CHAPTER 8 Colour Palette OMRON Page 138 Revision 2 0...