pszOld (PSZ) - input

      Address of the ASCIIZ path name of the source file, subdirectory, or character device.

      Global file-name characters are not allowed.

    pszNew (PSZ) - input

      Address of the ASCIIZ path name of the target file, subdirectory, or character device.

      Global file-name characters are not allowed.

    option (ULONG) - input

      ULONG bit flags that define how the DosCopy function is done.

      Bit

        Description
      31-3
        Reserved. These bits must be set to zero.
      2
        DCPY_FAILEAS (0x00000004) Discard the EAs if the source file contains EAs and the destination file system does not support EAs.

      • Discard the EAs (extended attributes) if the destination file system does not support EAs.

      • Fail the copy if the destination file system does not support EAs.
      1
        DCPY_APPEND (x00000002)
        Append the source file to the target file's end of data.

      • Replace the target file with the source file.
      • Append the source file to the target file's end of data.

        This is ignored when copying a directory, or if the target file does not exist.

      0
        DCPY_EXISTING (0x00000001)
        Existing Target File Disposition.

      • Do not copy the source file to the target if the file name already exists within the target directory. If a single file is being copied and the target already exists, an error is returned.

      • Copy the source file to the target even if the file name already exists within the target directory.
      Bit flag DCPY_FAILEAS can be used in combination with bit flag DCPY_APPEND or DCPY_EXISTING.

    ulrc (APIRET) - returns

      Return Code.

      DosCopy returns one of the following values:

    • NO_ERROR 2
        ERROR_FILE_NOT_FOUND
      3
        ERROR_PATH_NOT_FOUND
      5
        ERROR_ACCESS_DENIED
      26
        ERROR_NOT_DOS_DISK
      32
        ERROR_SHARING_VIOLATION
      36
        ERROR_SHARING_BUFFER_EXCEEDED
      87
        ERROR_INVALID_PARAMETER
      108
        ERROR_DRIVE_LOCKED
      112
        ERROR_DISK_FULL
      206
        ERROR_FILENAME_EXCED_RANGE
      267
        ERROR_DIRECTORY
      282
        ERROR_EAS_NOT_SUPPORTED
      283
        ERROR_NEED_EAS_FOUND
      For a full list of error codes, see Errors.


    [Back] [Next]