XPRDfopen
| XPRDfopen | 
  Purpose
 
  Synopsis
 
XPRDfile XPRDfopen(XPRDmosel mosel, const char *fname, int mode, char *errmsg, int msglen);
 
  Arguments
 
| 
     mosel 
     | 
     Mosel instance
     | ||||||||||
| 
     fname 
     | 
     File name
     | ||||||||||
| 
     mode 
     | 
     Open mode (may be combined):
     
 | ||||||||||
| 
     errmsg 
     | 
     Buffer to return error message
     | ||||||||||
| 
     msglen 
     | 
     Size of
     errmsg
     | 
  Return value
 
 A file descriptor or
 NULL in case of failure.
  Example
 
 Open file
 "myfile" located in the temporary directory of instance
 minst for reading in binary mode:
 
f=XPRDfopen(minst, "tmp:myfile", XPRD_F_BINARY|XPRD_F_INPUT);
  Further information
 
 1. The specified file path is relative to the working directory of the Mosel instance performing the file operation.
 
 2. File operations are performed under the restrictions of the Mosel instance. For example, if the remote instance does not have write access, this routine will fail to open a file for writing.
 
 3. Just like accessing files from a Mosel model, any I/O drivers supported by the remote instance can be used with this routine. Drivers
 "sysfd:",
 "tmp:" and
 "shmem:" are therefore available.
 
  Related topics
 
 
