1

I wanna connect with API through Web Services

I've done everything like this: Integration with another system

and I get the same error: "The underlying connection was closed: An unexpected error occurred on a receive."

I also created a new class:

Class MyTestService
    Inherits SenditAPI.SendItpl
    Protected Overrides Function GetWebRequest(ByVal uri As Uri) As System.Net.WebRequest
        Dim webRequest As System.Net.HttpWebRequest
        webRequest = CType(MyBase.GetWebRequest(uri), System.Net.HttpWebRequest)
        'Setting KeepAlive to false 
        webRequest.KeepAlive = False
        GetWebRequest = webRequest
    End Function
End Class

according with http://support.microsoft.com/kb/915599

Community
  • 1
  • 1

1 Answers1

2

It seems to be a problem with configuration.

Check App.config file. The address in <value>...</value> seems to be incorrect.

XardasLord
  • 1,764
  • 2
  • 20
  • 45