Discuss (FTP), (FTP on .NET CF) and (FTPS, SFTP and SCP).
no avatar
User

idelsoni

Posts

8

Joined

Fri Jan 28, 2011 8:12 am

Invalid IP Addr causes edtFTP/Free to hang

by idelsoni » Tue Feb 15, 2011 4:48 am

I am using edtFTPNet/Free. If I pass an invalid IP Address to the connect method or the server is not on line my connect form hangs for a period of time until the connect() method finally times out.

Is this timeout interval settable via a property? If so, what is the property.

If the interval is not settable, I would like to know how I can stop the connect process myself after a given amount of time. I'm thinking of that I need to spin the connect() command off asynchronously. I would like to start the thread using BeginInvoke and then start my own timer. I'm hoping that I can poll the IsConnected property while edtFTPNet/Free is attempting to connect. How can I stop the connect process. Can I do it with an EndInvoke call or do I have to terminate my thread another way?

Thanks,
Ira Idelson
no avatar
User

support2

Posts

3987

Joined

Tue May 18, 2004 8:30 am

Re: Invalid IP Addr causes edtFTP/Free to hang

by support2 » Wed Feb 16, 2011 9:32 am

If you are using the latest version, the timeout applies to Connect().

However the DNS resolution of the hostname does not have a timeout (and that is done in Connect()). So it is possible that this is causing the hang.

Use the IP address rather than the hostname to confirm this.
no avatar
User

idelsoni

Posts

8

Joined

Fri Jan 28, 2011 8:12 am

by idelsoni » Thu Feb 17, 2011 11:05 pm

Bruce,

Thanks, I found the timeout command. It helps a lot.

Ira

Who is online

Users browsing this forum: No registered users and 15 guests

Powered by phpBB ® | phpBB3 Style by KomiDesign
cron