Connection failed - WeOnlyDo Discussion board

Connection failed (wodHttpDLX)

by Jefe, Saturday, June 18, 2005, 09:36 (6896 days ago)

Hi Group
I'm using HttpDlx dll and I have a problem with it:
I'm working on Simple Get sample of this component which accepts a URL and then retrieves its body but the problem is it will only work for the first time and after getting the body , if I click on Get button again it won't return any result and raises Disconnect event with 10060 error code which is a time-out error, Time-out value is 30 seconds and I have ADSL connection so this problem doesn't relate to internet connection and before trying to get the body again I'm waiting to get the Disconnected event.
Regards

Re: Connection failed

by wodSupport, Saturday, June 18, 2005, 16:02 (6896 days ago) @ Jefe

Jefe,

I really can't tell you why this error happens. Can you send us your project overhere so we can try to duplicate the problem?

Re: Connection failed

by Jefe, Sunday, June 19, 2005, 06:58 (6895 days ago) @ wodSupport

well it's one of your samples Simple Get but here is the code:

'Beginnig of the Code:
Private Sub cmdGet_Click()
wodHttp1.Get txtURL.Text
End Sub

Private Sub Form_Load()
Set wodHttp1 = New wodHttpDLXCom
wodHttp1.Timeout = 30

End Sub

Private Sub Form_Unload(Cancel As Integer)
Set wodHttp1 = Nothing
End Sub

Private Sub wodHttp1_Done(ByVal ErrorCode As Long, ByVal ErrorText As String)
If ErrorCode = 0 Then
txtResponse.Text = wodHttp1.Response.Body

Else
txtResponse.Text = ErrorText
End If
End Sub

Private Sub wodHttp1_StateChange(ByVal OldState As wodHttpDLXComLib.HttpStates)

Label4.Caption = wodHttp1.StateString(wodHttp1.State)
End Sub

'End of the Code

Regards

Re: Connection failed

by wodSupport, Sunday, June 19, 2005, 23:23 (6895 days ago) @ Jefe

Jeffe,

I tried to duplicate your problem with our '1. Simple GET' sample, by opening http://www.weonlydo.com - and it works correctly each time. I'm not sure what could be the cause for error you experience.

What page are you trying to open? Does same behavior happens with IE if you press refresh on it while opening same page? Do you use proxy with IE?

Re: Connection failed

by Jefe, Monday, June 20, 2005, 07:03 (6894 days ago) @ wodSupport

Well I tried it with the same URL and even Google and Yahoo but it didn't work, do you wait for a certain time before trying to regetting the body as soon as the state becomes NotConnected you tried it? and also, the state will be changed to NotConnected but Disconnected event will not be raised!!!!
Regards

Re: Connection failed

by Jefe, Monday, June 20, 2005, 07:14 (6894 days ago) @ Jefe

Jeffe,

What page are you trying to open? Does same behavior happens with IE if you press refresh on it while opening same page? Do you use proxy with IE?

Well I'm working on a workstation in a LAN so some NATtin happens and also they Filter my URLs and my ISP will do that too, I don't know if that could relate to our problem.

Re: Connection failed

by wodSupport, Tuesday, June 21, 2005, 01:25 (6894 days ago) @ Jefe

Jefe,

yes, I wait until body is fully retrieved and state changed to 'Not Connected' before I click on 'Get' button again.

Re: Connection failed

by jefe, Tuesday, June 21, 2005, 06:54 (6893 days ago) @ wodSupport

Jefe,

yes, I wait until body is fully retrieved and state changed to 'Not Connected' before I click on 'Get' button again.

That's exactly what I did but it didn't work!!!

Re: Connection failed

by Deepthi, Friday, July 06, 2007, 11:55 (6148 days ago) @ jefe

well it's one of your samples Simple Get but here is the code:

'Beginnig of the Code:
Private Sub cmdGet_Click()
wodHttp1.Get txtURL.Text
End Sub

Private Sub Form_Load()
Set wodHttp1 = New wodHttpDLXCom
wodHttp1.Timeout = 30

End Sub

Private Sub Form_Unload(Cancel As Integer)
Set wodHttp1 = Nothing
End Sub

Private Sub wodHttp1_Done(ByVal ErrorCode As Long, ByVal ErrorText As String)
If ErrorCode = 0 Then
txtResponse.Text = wodHttp1.Response.Body

Else
txtResponse.Text = ErrorText
End If
End Sub

Private Sub wodHttp1_StateChange(ByVal OldState As wodHttpDLXComLib.HttpStates)

Label4.Caption = wodHttp1.StateString(wodHttp1.State)
End Sub

'End of the Code

Regards

Re: Connection failed

by wodDamir, Friday, July 06, 2007, 12:00 (6148 days ago) @ Deepthi

Deepthi,

You just quoted one of the first posts in this thread. Is there an issue you are experiencing? Could you describe it?

Regards,
Damba