CRE Programmer's Guide

CRE Service Functions
Common Run-Time Environment (CRE) Programmer’s Guide528146-004
6-23
CRE_File_Setmode_
error
if present and greater than or equal to zero, is a file system error code; otherwise,
if present and less than zero,
error is a negated CRE error ordinal.
Return Value
CRE_File_Retrycheck_ returns 0 if file_ordinal is not valid or if error is present
and has a negative value; otherwise, CRE_File_Retrycheck_ returns the value
returned to it from a call to the FILEERROR system procedure. See “FILEERROR” in
the
Guardian Procedure Calls Reference Manual for more information on the
FILEERROR procedure.
Considerations
Retrying an operation is appropriate only if:
°
The last operation failed.
°
The failure was detected by the operating system.
°
The cause of the failure is considered recoverable.
CRE_File_Retrycheck_ does not return errors.
CRE_File_Setmode_
The CRE_File_Setmode_ function invokes the SETMODE or the SPOOLSETMODE
system procedure, passing the parameters you specify when you call
CRE_File_Setmode_.
file_ordinal
identifies the standard file to which to send a setmode operation. You can use the
following symbolic names for
file_ordinal:
CRE^Standard^Input
CRE^Standard^Output
CRE^Standard^Log
function
is the function parameter for a SETMODE or SPOOLSETMODE system
procedure.
INT PROC CRE_File_Setmode_( file_ordinal, function, param1,
param2 ) EXTENSIBLE;
INT file_ordinal; ! in, required
INT function; ! in, required
INT param1; ! in, required
INT param2; ! in, optional TNS,native