mode (ULONG) - input

      Contents of the fsOpenMode field defined in a previous DosOpen function.

      This parameter contains the following bit fields:

      Bit

        Description
      15
        OPEN_FLAGS_DASD (0x00008000)
        This bit must be set to 0.
      14
        OPEN_FLAGS_WRITE_THROUGH (0x00004000)
        Write-Through flag:

      • Writes to the file may go through the system-buffer cache.

      • Writes to the file may go through the system-buffer cache, but the data is written (the actual file I/O operation is completed) before a synchronous-write call returns. This state of the file defines it as a synchronous file. For synchronous files, this bit must be set, because the data must be written to the medium for synchronous-write operations.

        This flag bit is not inherited by child processes.

      13
        OPEN_FAIL_ON_ERROR (0x00002000)
        Fail-Errors flag. Media I/O errors are handled as follows:

      • Reported through the system critical-error handler.
      • Reported directly to the caller by way of a return code.

        Media I/O errors generated through Category 08h Logical Disk Control IOCtl Commands are always reported directly to the caller by way of a return code. The Fail-Errors function applies only to non-IOCtl handle-based file I/O functions.

        This flag bit is not inherited by child processes.

      12
        OPEN_FLAGS_NO_CACHE (x00002000)
        Cache or No-Cache flag. The file is opened as follows:

      • The disk driver should place data from I/O operations into cache.
      • I/O operations to the file need not be done through the disk-driver cache.

        This bit is an advisory bit, and is used to advise file-system drivers and device drivers about whether the data should be cached. This bit, like the write-through bit, is a per-handle bit.

        This bit is not inherited by child processes.

      11-8
        These bits must be set to 0.
      7
        OPEN_FLAGS_NOINHERIT (0x00000080)
        Inheritance flag:

      • File handle is inherited by a process created by DosExecPgm.
      • File handle is private to the current process.
      6-4
        These bits must be set to 0. Any other values are invalid.
      3
        This bit must be set to 0.
      2-0
        These bits must be set to 0. Any other values are invalid.


      [Back] [Next]