function DelDir(directory)


The DelDir function deletes a directory, if it's empty.
This function returns true if the directory was successfully deleted. If the directory isn't empty, or if for any other reason it could not be deleted, this function returns false.


Example:

{
 var scli = new SftpClient();
 scli.Host = 'your.sftpserver.com:22';
 scli.User = 'someusername';
 scli.KeyFile = './my_id.rsa';
 if (scli.Connect()) {
  // perform your file transfers...
  // ...
  scli.DelDir('/docs/some_empty_directory');
  // ...
  scli.Close();
 }
 scli = null
}