0

在 VS2005 VB.NET 项目中,我们使用第三方 asmx 服务来转换帐号。

在开发机器上一切正常,但在生产服务器上,当我们调用服务时会抛出异常。

这是一个例外:

System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a receive. ---> System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   --- End of inner exception stack trace ---
   at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Net.PooledStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.Net.Connection.SyncRead(HttpWebRequest request, Boolean userRetrievedStream, Boolean probeRead)
   --- End of inner exception stack trace ---
   at System.Web.Services.Protocols.WebClientProtocol.GetWebResponse(WebRequest request)
   at System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse(WebRequest request)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
   at KlantenApplicatie.BL.IbanConversie.IBANBIC.calculateIBAN1(String ISOcountry, String account)
   at KlantenApplicatie.BL.Relatie.SpecGegFiscTOWBasisinfoBL.convertToIban(String rekeningNummer)

出现异常需要一些时间。

网络服务是:http ://www.ebcs.be/iban/IBANBIC.asmx

4

1 回答 1

0

问题是 Internet Explorer 中的代理配置错误。当我调整它时,一切正常。

于 2013-03-27T09:53:56.323 回答