Hi
I'm trying out the edtFTPnet Pro component with sftp.
I can get synchronous transfers to work ok but but I'm having great difficulty with asynchronous methods.
I'm using some of the sample code from 'How to use asynchronous methods' example in the example viewer -
sftpConnection.BeginConnect(New AsyncCallback(AddressOf OnConnect), sftpConnection)
followed eventually by -
Private Sub OnConnect(ByVal ar As IAsyncResult)
Dim c As SecureFTPConnection = CType(ar.AsyncState, SecureFTPConnection)
c.EndConnect(ar)
AddToList("Connect completed", True)
End Sub 'OnConnect
My problem is that the OnConnect sub is never fired. The app cycles through all the main 'Begin' operations and then just waits there for the Signaller event to fire, which it never does.
As I said, it all works fine in synchronous mode so all my connections are ok.
The 'How to use asynchronous methods' example in the example viewer works ok too.
Is it possible to obtain the sample code as a VB application?
I'm new to .net and threading is a bit of an unknown to me. The complete working 'How to use asynchronous methods' example app code would be a huge help in my understanding of whats going on.
I'd really appreciate any help.
Regards
Malcom