Back to product page
- Introduction
- License agreement
- Getting Started
- Objects
- Enumerations
- wodFtpDLX
- Methods
- Abort
- About
- AppendData
- AppendFile
- AppendFileFrom
- CheckDir
- ClearCommandChannel
- Connect
- DeleteFile
- DeleteFiles
- Disconnect
- GetAttributes
- GetData
- GetDate
- GetFile
- GetFileAt
- GetFileAt64
- GetFiles
- GetSize
- ListDir
- ListNames
- LocalCRC
- LoopFiles
- MakeDir
- PutData
- PutFile
- PutFileAt
- PutFileAt64
- PutFiles
- RawReceived
- RawSend
- Refresh
- RemoteCRC
- RemoveDir
- Rename
- SetAttributes
- SetAttributes64
- Site
- Properties
- Account
- Arrange
- AscIITranslation
- Authentication
- BackColor
- Blocking
- BorderVisible
- BufferSize
- Certificate
- ClientName
- ColumnCount
- ColumnHeader
- Columns
- ColumnWidth
- Compression
- ContextMenu
- DirFormat
- DirItems
- Enabled
- Encryption
- EncryptionList
- ErrorText
- FIPS
- ForeColor
- HMacList
- Hostname
- IconView
- ItemSkip
- KeepAlive
- LastError
- ListItem
- ListParams
- LocalCertBag
- LocalPath
- Login
- MaxDataPort
- MaxTransferRate
- MinDataPort
- MyHostname
- MyIP
- Notification
- Passive
- Password
- PasvPort
- Port
- Protocol
- ProxyHostname
- ProxyLogin
- ProxyPassword
- ProxyPort
- ProxyType
- RemotePath
- Resume
- SecureMethod
- ShellIcons
- SmartGet
- SmartPut
- SortItems
- SSLCipherList
- State
- StateText
- StrictHost
- TabStop
- Tag
- Timeout
- Timezone
- TransferMode
- TransferRate
- TransferTime
- UseIPv6
- UTF8Encoding
- Version
- Events
- ActionCopy
- ActionDelete
- ActionDownload
- ActionMakeDir
- ActionNewFile
- ActionPaste
- ActionProperties
- ActionRename
- ActionSelect
- AfterViewChange
- Attributes
- Attributes64
- Banner
- BeforeViewChange
- Click
- ClientCertRequired
- Connected
- CryptoInformation
- DblClick
- Disconnected
- Done
- FileTransferData
- Focus
- FTPReply
- HostCertificate
- HostFingerprint
- KeyPress
- ListItems
- LoginChallenge
- LoopError
- LoopItem
- MenuClick
- PreTranslateCommand
- PreTranslateReply
- Progress
- Progress64
- ShowContextMenu
- SiteReply
- StateChange
- Methods
- IwodFtpNotify
- DirItem
- DirItems
- How to get support?
- Technical information
- Fast notifications interface
- Error list
- How to...
GetFile method
Retrieves file or folder date.
Type
NoneSyntax
- Basic
object.GetFile[LocalPath], [RemoteFile]
The GetFile(object,LocalPath,RemoteFile) syntax has these parts:
The GetFile(object,LocalPath,RemoteFile) syntax has these parts:
object | An expression evaluating to an object of type wodFtpDLX. |
LocalPath | Optional. A Variant value. Full path to filename (or directory) on your local disk. If left empty then FileTransferData event will be fired during file transfer. |
RemoteFile | Optional. A Variant value. Full path to filename on the server. |
Remarks
GetFile method will initiate copying of file residing on remote server to the local computer. During the transfer, Progress event will be fired several times, depending on your network speed and length of the file. When the copying is completed, Done event will be fired. If an error occurs during transfer, Done event will be fired immediately containing ErrorCode and description for the error, and transfer will be aborted. If you want to continue it later, or try to re-receive the file, initiate GetFile method again (immediately or after reconnecting, depends on error that occurred). You may also use Resume property to resume transferring from the position where the error occurred. This method can be initiated only when State property is set to Connected. You cannot receive file if wodFtpDLX is busy doing something else. Although RemoteFile argument MUST contain full path including filename of the file you wish to receive, you can omit LocalPath argument. For instance, you can setLocalPath = "C:\Temp"
in which case wodFtpDLX will automatically copy it with the same name as it is on remote server. If you wish to specify that is copied with some other name, you have to include it in LocalPath argument. If you don't specify LocalPath or RemoteFile argument, wodFtpDLX will use values set in LocalPath and RemotePath properties. If LocalPath is still empty (or set to ""), then no local file will be used to write file to, FileTransferData event will be fired instead where you read byte array of data by yourself, and save it somewhere (or just ignore... your choice). No wildcards can be used for RemotePath argument. RFC protocol specifications for FTP and SFTP do not allow them. Do not forget that RemoteFile should always specify full absolute path (i.e. /home/joe/something) instead of relative path (i.e. joe/something). LocalPath should also specify full path (i.e. C:\home\joe\something) instead of relative path (i.e. joe\something).