FTPConnectionDirectoryExists Method
Tests if the given directory exists.
Namespace: EnterpriseDT.Net.FtpAssembly: edtFTPnetPRO (in edtFTPnetPRO.dll) Version: 12.7.0.0
public virtual bool DirectoryExists(
string remoteDirectory
)
Public Overridable Function DirectoryExists (
remoteDirectory As String
) As Boolean
public:
virtual bool DirectoryExists(
String^ remoteDirectory
)
abstract DirectoryExists :
remoteDirectory : string -> bool
override DirectoryExists :
remoteDirectory : string -> bool
- remoteDirectory String
-
Booleantrue if directory exists and false otherwise
The FTP protocol doesn't specify a standard way of testing for the existence of a directory, so
this method tries to change into the directory and assumes that that the directory doesn't
exist if an exception is thrown. The current working directory is restored before the method
returns.