CRE Programmer's Guide
CRE Service Functions
Common Run-Time Environment (CRE) Programmer’s Guide—528146-004
6-13
CRE_File_Open_
exclusion corresponds to the exclusion parameter to the FILE_OPEN_ system 
procedure. 
Refer to the FILE_OPEN_ procedure in the 
Guardian Procedure Calls Reference 
Manual for valid access parameter values. 
no_wait
if present, is the nowait parameter to pass to the FILE_OPEN_ system procedure. 
CRE_File_Open_ returns an error if you specify a nonzero value for 
no_wait. If 
you do not specify 
no_wait, CRE_File_Open_ uses a value of zero. 
sync_receive_depth
if present, is the sync-or-receive-depth parameter to pass to the FILE_OPEN_ 
system procedure. The value passed to FILE_OPEN_ is determined as follows:
•
If sync_receive_depth is present and nonzero, CRE_File_Open_ passes 
sync_receive_depth to FILE_OPEN_.
•
If sync_receive_depth is present and zero, CRE_File_Open_ passes zero 
to FILE_OPEN_ unless:
°
Your program is compiled to run as a process pair
°
Your program includes more than one language (not including TAL and 
pTAL)
In these cases, the CRE specifies 1 for the FILE_OPEN_ sync-or-receive-
depth parameter.
•
If sync_receive_depth is not present, the CRE specifies 1 for the 
FILE_OPEN_ sync-or-receive-depth parameter, except for $RECEIVE, for 
which it specifies 0.
options
if present, is the options parameter for FILE_OPEN_. If you do not specify 
options, CRE_File_Open_ passes zero to FILE_OPEN_, unless the access 
mode is read-only and the file is $RECEIVE (TNS CRE environment only), in which 
case it passes one to FILE_OPEN_.
cplist
if present and its address value is nonzero in the TNS environment, is a checkpoint 
list. In the native CRE environment, this parameter has no meaning and should be 
left empty (it is used by COBOL for process pair execution).
Return Value
CRE_File_Open_ returns one of the following:
•
0 if the open operation is successful










