Unit

ScSFTPUtils

 

type

 TScSFTPFileOpenMode = (fmCreateNew, fmCreateOrTruncate, fmOpenExisting, fmOpenOrCreate, fmTruncateExisting);;

 

Description

The TScSFTPFileOpenMode enumeration represents modes of the file opening.

 

ValueMeaning
fmCreateNewa new file is created; if the file already exists, the server returns the SSH_FX_FILE_ALREADY_EXISTS error.
fmCreateOrTruncatea new file is created; if the file already exists, it is opened and truncated.
fmOpenExistingan existing file is opened. If the file does not exist, the server returns  the SSH_FX_NO_SUCH_FILE error. If a directory in the path does not exist, the server returns the  SSH_FX_NO_SUCH_PATH or SSH_FX_NO_SUCH_FILE error.
fmOpenOrCreateif the file exists, it is opened. If the file does not exist, it is created.
fmTruncateExistingan existing file is opened and truncated. If the file does not exist, the server returns the same error codes as defined for fmOpenExisting.

 

See also

TScSFTPClient.OpenFile

 

SecureBridge Components, Copyright © 2007-2024 Devart. All Rights Reserved. Provide Feedback Visit Forum Request Support