Xceed .NET Libraries Documentation
PassiveTransfer Property (FtpClient)


Xceed.Ftp Assembly > Xceed.Ftp Namespace > FtpClient Class : PassiveTransfer Property
Gets or sets a boolean value indicating if the FTP client should initiate the data connection rather than the FTP server.
Syntax
'Declaration
 
Public Property PassiveTransfer As Boolean
'Usage
 
Dim instance As FtpClient

Dim value As Boolean

 

instance.PassiveTransfer = value

 

value = instance.PassiveTransfer
public bool PassiveTransfer {get; set;}

Property Value

true if the FTP client should initiate the data connection; false otherwise. By default, this property is set to true.
Remarks

If set to true, the PASV command will be sent to the FTP server rather than the PORT command resulting in the FTP server "listening" on a data port (other than its default) and waiting for a data connection to be established by the FTP client. If set to false, the PORT command will be sent and the FTP client will be listening for an incoming data connection. The FTP server will establish the data connection upon receipt of a transfer command.

The reply to the PASV command includes the host and port address the FTP server is listening on.

If you are having issues connecting or sending and receiving files to and from a server, try setting the PassiveTransfer property to true.

This property is the equivalent of the PassiveMode property of the ActiveX version of the Xceed FTP Library.

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

FtpClient Class
FtpClient Members