Read; Readmessage - Omron CX-Supervisor Reference Manual

Script language reference
Hide thumbs Also See for CX-Supervisor:
Table of Contents

Advertisement

File Commands
Note:
6-9-8

Read

Note:
6-9-9

ReadMessage

82
Argument
Type
returnstate
bool
Filename
string
Typical Example
PrintFile("c:\autoexec.bat")
The file "c:\autoexec.bat" is sent to the currently configured printer.
Script commands that have textual arguments can take either literal strings
within quotes or text points.
CX-Supervisor uses the OLE registration information (file extension
associations) to decide how to print a file. It invokes the parent application
associated with a particular file extension, instructing the application to start
minimised and passing the "print" command. For example, if the file extension
.txt is associated with Notepad, then Notepad is invoked to print the file.
Syntax
returnstate = Read(RecordId, pointname, ...)
Remarks
Argument
Type
returnstate
bool
RecordId
integer
Pointname
point
Typical Examples
Read(1, value)
The point 'value' is loaded with the value read from the currently open file
using the value of 1 as an index into the file.
ReadOK = Read(indexno, value1, value2, value3)
The points 'value1', 'value2', 'value' are loaded using the value of indexno as
an index into the file. Pass or fail status is stored in 'ReadOK'.
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).
Syntax
returnstate
textpoint, noofchars)
Remarks
Argument
Type
returnstate
bool
Filename
string
SECTION 6 Functions and Methods
Description
Returnstate is '1' if the function is successful, or
'0' otherwise.
Pathname of file to be printed.
Description
Returnstate is '1' if the function is successful, or
'0' otherwise.
An index into the file.
Name(s) of point(s) to be updated with the data
read from the open file.
=
ReadMessage
Description
Returnstate is '1' if the function is successful, or
'0' otherwise.
Pathname of file to be read.
("filename",
offset,

Advertisement

Table of Contents
loading

This manual is also suitable for:

Cx-supervisor 3.1

Table of Contents