Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
3.7k views
in .NET FTP by (360 points)
I am trying to make a quick and simple FTP client for my app and need to know how to collect the files that have been added to the local list control.
I am working in VB.Net.
I tried adding an event handler
  AddHandler ftpConnection.Downloaded, AddressOf AddFiletoFTPLocalList

    Public Sub AddFiletoFTPLocalList(ByVal sender As Object, ByVal e As EnterpriseDT.Net.Ftp.FTPFileTransferEventArgs)
        Dim LocalFile As String = e.LocalFile
        MsgBox(LocalFile)
    End Sub


not working, any help?
TIA

5 Answers

0 votes
by (51.6k points)
Could you please explain in a little more detail what you're trying to do? I don't quite follow it. In particular, I don't know what you mean by "collect the files that have been added to the local list control". Are these files that the user has downloaded? Or are they files that are already in the local directory?

- Hans (EnterpriseDT)
0 votes
by (360 points)
I need to catch the files that the user has downloaded. Since they can use the context menu or drag and drop I need a list of files that they have downloaded to the local list. I do not care about what was already in there and they can not upload so only the files they download.
Thanks
0 votes
by (162k points)
It sounds like you need to use the Downloaded event, which will be triggered every time a file is downloaded.
0 votes
by (360 points)
OK
The event is listed in the secureFTPConnection object not the List.
So I did not need to create an event handler for the list I needed to use the connection events.
0 votes
by (162k points)
Yes, the SecureFTPConnection knows about what has been transferred.

Categories

...