This project is read-only.

FTPfileInfo supports only files

Apr 5, 2007 at 4:28 PM
Edited Apr 5, 2007 at 5:05 PM
the constructer of FTPfileInfo is expecting size to be non-blank, but for a directory it is blank hence there is an exception.

does anyone have an elegant fix to this problem? (maybe extend FileInfo to support both files and directories?)
---------
this fixed my problem:
In the constructor for FTPFileInfo, i made the below change.

If ((m.Groups("size").Value.Trim.Length) = 0) Then
_size = 0
Else
_size = CLng(m.Groups("size").Value)
End If
Coordinator
Apr 8, 2007 at 10:40 AM
This discussion has been copied to Work Item 1738. You may wish to continue further discussion there.