Determine the file transfer type based on the file extension or contents.
This method returns a boolean value. If the method succeeds, the return value is true. If the method fails, the return value is false. To get extended error information, check the value of the LastError property.
This method is used to determine the file transfer type to be used when uploading or downloading files. This method is used internally to determine the transfer mode when the FileType property is set to FileTransferType.fileAuto.
If the file extension or contents are not recognized, the default file transfer type for the client session will be returned. This will usually be FtpFileType.fileImage, however this can be changed by calling the AddFileType method. The file type for the current client session can be explicitly set using the FileType property.
If the bScanFile parameter is true and the file does not exist, is currently locked or has been opened exclusively by another process, the file type associated with the file extension will be returned instead. Text files which contain UTF-16 text will always return a file type of FtpFileType.fileImage because they can contain embedded null characters.