Hello,
I have similar problem but with file downloading.
I use class: FTPClient
Method: Get(string localPath, string remoteFile) .
Private method from this class: GetASCII(string localPath, string remoteFile)
uses streams without encoding information:
// create the buffered stream for writing
StreamWriter output = new StreamWriter(localPath);
// get an character input stream to read data from ... AFTER we
// have the ok to go ahead AND AFTER we've successfully opened a
// stream for the local file
StreamReader input = null;
try
{
input = new StreamReader(data.DataStream);
I changed it to:
// create the buffered stream for writing
System.Text.Encoding encoding = System.Text.Encoding.GetEncoding(1250);
StreamWriter output = new StreamWriter(localPath, false, encoding);
// get an character input stream to read data from ... AFTER we
// have the ok to go ahead AND AFTER we've successfully opened a
// stream for the local file
StreamReader input = null;
try
{
input = new StreamReader(data.DataStream, encoding);
and it work correctly.
I think the same problem is during a file uploading.
Maybe it will help....
Best regards,
Grzegorz