Xceed .NET Libraries Documentation
TraceWriter Property (FtpClient)
Example 


Xceed.Ftp Assembly > Xceed.Ftp Namespace > FtpClient Class : TraceWriter Property
Gets or sets the System.IO.TextWriter which will trace the connection/deconnection process as well as the commands and replies sent to and received from the FTP server.
Syntax
'Declaration
 
Public Property TraceWriter As TextWriter
'Usage
 
Dim instance As FtpClient

Dim value As TextWriter

 

instance.TraceWriter = value

 

value = instance.TraceWriter
public TextWriter TraceWriter {get; set;}

Property Value

A reference to a System.IO.TextWriter which will trace the connection/deconnection process as well as the commands and replies sent to and received from the FTP server. By default this property is set to a null reference (Nothing in Visual Basic); therefore, no tracing is done.
Remarks

The FTP client will not dispose/close the writer.

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

Example
The following example demonstrates how to write to a StreamWriter.
Dim ftp As New FtpClient() ftp.TraceWriter = New StreamWriter( "d:\ftp.log" )
FtpClient ftp = new FtpClient(); ftp.TraceWriter = new StreamWriter( @"d:\ftp.log" );
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