OnConnect Event no longer fires (wodFTPServer)

by Bob Perkins @, (4622 days ago)

I have the following code:

FTPSite := TwosSFTP.Create(nil);
FTPSite.OnConnected := Self.FTPSiteConnected;
FTPSite.OnDone := Self.FTPSiteDone;
FTPSIte.Hostname := FTPServer;
FTPSite.login := UserName;
FTPSite.password := Password;
FTPSite.Authentication := authPassword;
FTPSite.ProxyType := proxyNone;
FTPSite.RemotePath := ServerFile;
FTPSite.LocalPath := LocalPath;
FTPSite.Connect;

And the OnConnected event does not get executed. I few months ago this code worked just fine. In fact my boss using it in another program and it works fine. Now in this program it has decided not fire the routine.

Any insight into what I've done wrong is greatly appreciated.

locked

Re: OnConnect Event no longer fires

by wodDamir @, (4622 days ago) @ Bob Perkins

Bob,

Can you try Connect1 method instead? Is it available? Usually Delphi wrapper creates it instead of Connect.

Regards,
Damba

locked

Re: OnConnect Event no longer fires

by bob perkins @, (4622 days ago) @ wodDamir

Bob,

Can you try Connect1 method instead? Is it available? Usually Delphi wrapper creates it instead of Connect.

Regards,
Damba


There is no connect1 method in the interface file, only the connect.

locked

Re: OnConnect Event no longer fires

by wodDamir @, (4622 days ago) @ bob perkins

Bob,

Can you send us the sample project to techsupport@weonlydo.com? I'd like to try your project.

If I start same project form scratch here it works fine.

Regards,
Damba

locked

Re: OnConnect Event no longer fires

by bob perkins @, (4621 days ago) @ wodDamir

Bob,

Can you send us the sample project to techsupport@weonlydo.com? I'd like to try your project.

If I start same project form scratch here it works fine.

Regards,
Damba

My program file e-mail got rejected by your server. I've been playing with the control now for two days. Today I watched the OnConnect event sometimes fire off and sometimes not. I've had to change my code to handle if that works or when that doesn't I go into a brute force sending method where I have a serious of loops waiting ofr state changes in the control. It is not pretty and I neither are the comments explaining why it is done in such a manner. Hopefully I've covered all my bases and I can push the files out.

locked

Re: OnConnect Event no longer fires

by woddrazen @, (4621 days ago) @ bob perkins

Bob,


Did you maybe set Blocking Property to True inside your code? If you didn't Connected Event should be fired when you run Connect Method.

If you have issue is there any chance we can duplicate it on our side? Which email address you are using?


Drazen

locked

Re: OnConnect Event no longer fires

by Bob Perkins @, (4621 days ago) @ woddrazen

Bob,


Did you maybe set Blocking Property to True inside your code? If you didn't Connected Event should be fired when you run Connect Method.

If you have issue is there any chance we can duplicate it on our side? Which email address you are using?


Drazen

I have not intentionally set blocking property. I instansiate an instance of the class, set the credentials and other pertinant properties to send and then connect.

I sent my example to the e-mail address listed in the previous posting. I cut and pasted to avoid typos but I will try again.

locked