Connection failed (wodHttpDLX)
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
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
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
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
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
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
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
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
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 SubPrivate Sub Form_Load()
Set wodHttp1 = New wodHttpDLXCom
wodHttp1.Timeout = 30
End SubPrivate Sub Form_Unload(Cancel As Integer)
Set wodHttp1 = Nothing
End SubPrivate 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 SubPrivate Sub wodHttp1_StateChange(ByVal OldState As wodHttpDLXComLib.HttpStates)
Label4.Caption = wodHttp1.StateString(wodHttp1.State)
End Sub'End of the Code
Regards
Re: Connection failed
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