Back to product page
- Introduction
- License agreement
- Classes
- Enumerations
- Exceptions
- WeOnlyDo.Client.FtpDLX
- Properties
- Authentication
- Blocking
- BufferSize
- Certificate
- Compression
- DirFormat
- DirItems
- Encryption
- Hostname
- KeepAlive
- LastError
- ListItem
- ListParams
- LocalPath
- Login
- MaxTransferRate
- Passive
- Password
- Port
- PreserveDates
- PrivateKey
- Protocol
- ProxyHostname
- ProxyLogin
- ProxyPassword
- ProxyPort
- ProxyType
- PublicKeyOpenSSH
- PublicKeySSH
- RemotePath
- Resume
- SecureMethod
- SmartGet
- SmartPut
- State
- StrictHost
- Tag
- Timeout
- Timezone
- TransferMode
- TransferRate
- TransferTime
- UseIPv6
- Version
- Methods
- Events
- Properties
- WeOnlyDo.Client.DirItemsCollection
- WeOnlyDo.Client.DirItem
- How to get support?
ListNames method
Lists names in the directory on the server.
Type
VoidSyntax
- C#
- VB.NET
public Void ListNames();
public Void ListNames(Stream ToStream);
The ListNames(ToStream) syntax has these parts:
public Void ListNames(String RemotePath);
The ListNames(RemotePath) syntax has these parts:
public Void ListNames(String RemotePath, Stream ToStream);
The ListNames(RemotePath,ToStream) syntax has these parts:
public Void ListNames(Stream ToStream);
The ListNames(ToStream) syntax has these parts:
ToStream | Local stream that where wodFtpDLX.NET will write data to. |
public Void ListNames(String RemotePath);
The ListNames(RemotePath) syntax has these parts:
RemotePath | Full path to a directory on the server. |
public Void ListNames(String RemotePath, Stream ToStream);
The ListNames(RemotePath,ToStream) syntax has these parts:
RemotePath | Full path to a directory on the server. |
ToStream | Local stream that where wodFtpDLX.NET will write data to. |
public Sub ListNames()
public Sub ListNames(ByVal ToStream As Stream)
The ListNames(ToStream) syntax has these parts:
public Sub ListNames(ByVal RemotePath As String)
The ListNames(RemotePath) syntax has these parts:
public Sub ListNames(ByVal RemotePath As String, ByVal ToStream As Stream)
The ListNames(RemotePath,ToStream) syntax has these parts:
public Sub ListNames(ByVal ToStream As Stream)
The ListNames(ToStream) syntax has these parts:
ToStream | Local stream that where wodFtpDLX.NET will write data to. |
public Sub ListNames(ByVal RemotePath As String)
The ListNames(RemotePath) syntax has these parts:
RemotePath | Full path to a directory on the server. |
public Sub ListNames(ByVal RemotePath As String, ByVal ToStream As Stream)
The ListNames(RemotePath,ToStream) syntax has these parts:
RemotePath | Full path to a directory on the server. |
ToStream | Local stream that where wodFtpDLX.NET will write data to. |
Remarks
ListNames method will send request to the server to retrieve only names of files and directories in the given path. Once server sends data, ListItems event will be fired containing all the files listed by the server - each one in separate line, split by CRLF sequence. If wodFtpDLX.NET detects that item is a directory, it will append / (slash) to the end of it.Once completed, Done event will be fired. If no error occurs, Args.Error argument in Done event will be set to null (Nothing in VB). If error occurred, Args.Error will contain description of the error.
To retrieve full listing of files/directories on a given path (including size, permissions, dates...) you should use ListDir method.
No wildcards can be used for RemotePath argument. RFC protocol specification for SFTP does 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).