Back to product page

DeleteFile method


Deletes file on the server.

Type

None

Syntax

  • Basic
object.CoDeleteFilenect[RemotePath]
The DeleteFile(object,RemotePath) syntax has these parts:
objectAn expression evaluating to an object of type wodFtpDLX.
RemotePathOptional. A Variant value. Full path to file on remote server that should be deleted.

Remarks

This method will delete file on remote server, if possible. Once completed, Done event will be fired. If no error occurs, ErrorCode argument in Done event will be set to 0 (zero). If error occurred, ErrorCode will hold number for the error, and ErrorText will contain description for the error.

No wildcards can be used for RemotePath argument. RFC protocol specifications for FTP and SFTP do not allow them.

Do not forget that RemotePath should always specify full absolute path (i.e. /home/joe/something) instead of relative path (i.e. joe/something).

Platforms

Windows