Guardian Procedure Calls Reference Manual (G06.25+)
Guardian Procedure Calls (D-E)
Guardian Procedure Calls Reference Manual—522629-013
4-101
EDITREAD Procedure
EDITREAD Procedure
Summary
Syntax for C Programmers
Syntax for TAL Programmers
Parameters
Example
Summary
The EDITREAD procedure reads text lines from an EDIT file (file code = 101).
Text lines are transferred, in ascending order, from the text file to a buffer in the
application program’s data area. One line is transferred by each call to EDITREAD.
EDITREAD also returns the sequence number associated with the text line and
performs checks to ensure that the text file is valid.
The EDIT file can be opened nowait. However, a call to EDITREAD completes before
re tu r n i ng to t h e ap pl ic at io n pr o gra m ; i t i s n ot c o m p l e t ed wi th a c a l l t o AW AI T IO.
Syntax for C Programmers
•
CEXTDECS (via the included file TNSINTH) defines 32-bit values as the typedef
__int32_t which for TNS and TNS/R compiles is defined as
long and for TNS/E
compiles is defined as
int.
Syntax for TAL Programmers
Parameters
status returned value
INT
is a value indicating the outcome of EDITREAD. Values for
status are:
Note. Before EDITREAD is called, a call to EDITREADINIT must complete successfully.
#include <cextdecs(EDITREAD)>
short EDITREAD ( short _near *edit-controlblk
,char *buffer
,short bufferlen
,__int32_t *sequence-num );
status := EDITREAD ( edit-controlblk ! i,o
,buffer ! o
,bufferlen ! i
,sequence-num ); ! o