NET FTP Library
Dispose() Method
Example 






KellermanSoftware.NetFtpLibrary Namespace > FTP Class : Dispose() Method
Disposes the object by canceling any async transfer and destroying the FTPRequest object
Syntax
'Declaration
 
Public Sub Dispose() 
'Usage
 
Dim instance As FTP
 
instance.Dispose()
public void Dispose()
public procedure Dispose(); 
public function Dispose();
public: void Dispose(); 
public:
void Dispose(); 
Example
//Disposes the object by canceling any async transfer 
//and destroying the FTPRequest object 
 
// Dispose is called by .net when writing something like
using (FTP ftp = new FTP())
{
 
}
// dispose is called here for the ftp object
 
//Alternate way
FTP ftp = new FTP();
ftp.Dispose();
'Disposes the object by canceling any async transfer
'and destroying the FTPRequest object
 
' Dispose is called by .net when writing something like
Using ftp As FTP = New FTP()
 
End Using
' dispose is called here for the ftp object
 
'Alternate way
Dim ftp As FTP = New FTP()
ftp.Dispose()
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

FTP Class
FTP Members