问题描述
出异常:程序加载异常:没有终结点在侦听可以接受消息的http://localhost:8083/ApplyAuditService。这通常是由于不正确的地址或者SOAP操作导致的。如果存在此情况,请参见InnerException以了解详细信息。求问大神这是怎么回事啊!求解
解决方案
解决方案二:
<?xmlversion="1.0"?><!--有关如何配置ASP.NET应用程序的详细信息,请访问http://go.microsoft.com/fwlink/?LinkId=169433--><configuration><system.webServer><handlers><removename="ChartImageHandler"/><addname="ChartImageHandler"preCondition="integratedMode"verb="GET,HEAD,POST"path="ChartImg.axd"type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler,System.Web.DataVisualization,Version=4.0.0.0,Culture=neutral,PublicKeyToken=31bf3856ad364e35"/></handlers></system.webServer><appSettings><addkey="dbtype"value="oracle"/><addkey="IPadress"value="192.168.0.104"/><addkey="Port"value="1521"/><addkey="upfiles"value="D:/TOP/Upfiles/"/><addkey="connstr"value="DataSource=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.0.104)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));UserId=user;Password=password;"/><addkey="helpdoc"value="D:/TOP/helpdoc/helpdoc.doc"/><addkey="ChartImageHandler"value="storage=file;timeout=20;dir=TempImageFiles;"/></appSettings><connectionStrings><addname="ApplicationServices"connectionString="datasource=.SQLEXPRESS;IntegratedSecurity=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;UserInstance=true"providerName="System.Data.SqlClient"/></connectionStrings><system.web><httpHandlers><addpath="ChartImg.axd"verb="GET,HEAD,POST"type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler,System.Web.DataVisualization,Version=4.0.0.0,Culture=neutral,PublicKeyToken=31bf3856ad364e35"validate="false"/></httpHandlers><pages><controls><addtagPrefix="asp"namespace="System.Web.UI.DataVisualization.Charting"assembly="System.Web.DataVisualization,Version=4.0.0.0,Culture=neutral,PublicKeyToken=31bf3856ad364e35"/></controls></pages><compilationdebug="true"targetFramework="4.0"/><sessionStatemode="InProc"cookieless="false"timeout="120"/><membership><providers><clear/><addname="AspNetSqlMembershipProvider"type="System.Web.Security.SqlMembershipProvider"connectionStringName="ApplicationServices"enablePasswordRetrieval="false"enablePasswordReset="true"requiresQuestionAndAnswer="false"requiresUniqueEmail="false"maxInvalidPasswordAttempts="5"minRequiredPasswordLength="6"minRequiredNonalphanumericCharacters="0"passwordAttemptWindow="10"applicationName="/"/></providers></membership><profile><providers><clear/><addname="AspNetSqlProfileProvider"type="System.Web.Profile.SqlProfileProvider"connectionStringName="ApplicationServices"applicationName="/"/></providers></profile><roleManagerenabled="false"><providers><clear/><addname="AspNetSqlRoleProvider"type="System.Web.Security.SqlRoleProvider"connectionStringName="ApplicationServices"applicationName="/"/><addname="AspNetWindowsTokenRoleProvider"type="System.Web.Security.WindowsTokenRoleProvider"applicationName="/"/></providers></roleManager><authenticationmode="Forms"><formsname=".EDBFORMSAUTH"loginUrl="Login.aspx"defaultUrl="MainPage.aspx"timeout="1440"/><!--<formsname=".EDBFORMSAUTH"loginUrl="index.aspx"defaultUrl="HomePage.aspx"timeout="30"slidingExpiration="true"/>--></authentication><customErrorsmode="Off"defaultRedirect="Login.aspx"><errorstatusCode="403"redirect="NoAccess.htm"/><errorstatusCode="404"redirect="FileNotFound.htm"/></customErrors><globalizationrequestEncoding="gb2312"responseEncoding="gb2312"fileEncoding="gb2312"responseHeaderEncoding="gb2312"/></system.web><system.serviceModel><bindings><basicHttpBinding><bindingname="UploadFileService"closeTimeout="00:01:00"openTimeout="00:01:00"receiveTimeout="00:10:00"sendTimeout="00:01:00"allowCookies="false"bypassProxyOnLocal="false"hostNameComparisonMode="StrongWildcard"maxBufferSize="2147483647"maxBufferPoolSize="2147483647"maxReceivedMessageSize="9223372036854775807"messageEncoding="Mtom"textEncoding="utf-8"transferMode="Buffered"useDefaultWebProxy="true"><readerQuotasmaxDepth="32"maxStringContentLength="8192"maxArrayLength="16384"maxBytesPerRead="4096"maxNameTableCharCount="16384"/><securitymode="None"><transportclientCredentialType="None"proxyCredentialType="None"realm=""/><messageclientCredentialType="UserName"algorithmSuite="Default"/></security></binding><bindingcloseTimeout="00:10:00"receiveTimeout="00:20:00"sendTimeout="00:20:00"maxBufferSize="2147483647"maxReceivedMessageSize="2147483647"></binding></basicHttpBinding><wsHttpBinding><bindingcloseTimeout="00:10:00"receiveTimeout="00:20:00"sendTimeout="00:20:00"maxReceivedMessageSize="2147483647"></binding><bindingname="ApplyAuditService"closeTimeout="00:01:00"openTimeout="00:10:00"receiveTimeout="00:10:00"sendTimeout="00:10:00"bypassProxyOnLocal="false"transactionFlow="false"hostNameComparisonMode="StrongWildcard"maxBufferPoolSize="2147483647"maxReceivedMessageSize="9223372036854775807"messageEncoding="Text"textEncoding="utf-8"useDefaultWebProxy="true"allowCookies="false"><readerQuotasmaxDepth="2000000"maxStringContentLength="2147483647"maxArrayLength="2147483647"maxBytesPerRead="2147483647"maxNameTableCharCount="2147483647"/><reliableSessionordered="true"inactivityTimeout="00:10:00"enabled="false"/><securitymode="None"><transportclientCredentialType="Windows"proxyCredentialType="None"realm=""/><messageclientCredentialType="Windows"negotiateServiceCredential="true"/></security></binding><bindingname="AuthorizationComponent"closeTimeout="00:01:00"openTimeout="00:01:00"receiveTimeout="00:10:00"sendTimeout="00:01:00"bypassProxyOnLocal="false"transactionFlow="false"hostNameComparisonMode="StrongWildcard"maxBufferPoolSize="2147483647"maxReceivedMessageSize="9223372036854775807"messageEncoding="Text"textEncoding="utf-8"useDefaultWebProxy="true"allowCookies="false"><readerQuotasmaxDepth="32"maxStringContentLength="8192"maxArrayLength="16384"maxBytesPerRead="4096"maxNameTableCharCount="16384"/><reliableSessionordered="true"inactivityTimeout="00:10:00"enabled="false"/><securitymode="None"><transportclientCredentialType="Windows"proxyCredentialType="None"realm=""/><messageclientCredentialType="Windows"negotiateServiceCredential="true"/></security></binding><bindingname="BloodData"closeTimeout="00:01:00"openTimeout="00:01:00"receiveTimeout="00:10:00"sendTimeout="00:01:00"bypassProxyOnLocal="false"transactionFlow="false"hostNameComparisonMode="StrongWildcard"maxBufferPoolSize="2147483647"maxReceivedMessageSize="9223372036854775807"messageEncoding="Text"textEncoding="utf-8"useDefaultWebProxy="true"allowCookies="false"><readerQuotasmaxDepth="32"maxStringContentLength="8192"maxArrayLength="16384"maxBytesPerRead="4096"maxNameTableCharCount="16384"/><reliableSessionordered="true"inactivityTimeout="00:10:00"enabled="false"/><securitymode="None"><transportclientCredentialType="Windows"proxyCredentialType="None"realm=""/><messageclientCredentialType="Windows"negotiateServiceCredential="true"/></security></binding></wsHttpBinding></bindings><client><endpointaddress="http://192.168.0.104:8083/ApplyAuditService"binding="wsHttpBinding"bindingConfiguration="ApplyAuditService"contract="ApplyAuditService.IApplyAuditService"name="ApplyAuditService"/><endpointaddress="http://192.168.0.104:8084/UploadFileService"binding="basicHttpBinding"bindingConfiguration="UploadFileService"contract="UploadFileService.IUploadFile"name="UploadFileService"/><endpointaddress="http://192.168.0.104:8081/AuthorizationComponent"binding="wsHttpBinding"bindingConfiguration="AuthorizationComponent"contract="AuthorizationService.IAuthorizationService"name="AuthorizationComponent"/><endpointaddress="http://192.168.0.104:8082/BloodData"binding="wsHttpBinding"bindingConfiguration="BloodData"contract="BloodDataServie.IBloodData"name="BloodData"/></client><behaviors><serviceBehaviors><behavior><!--httpGetEnabled-bool类型的值,表示是否允许通过HTTP的get方法获取sevice的WSDL元数据--><serviceMetadatahttpGetEnabled="False"/></behavior></serviceBehaviors></behaviors></system.serviceModel></configuration>
解决方案三:
用了啥?webservice还是wcf?反正就是远端服务无法访问,从两方面检查1.地址是否写对2服务是否开启
解决方案四:
引用2楼BITxingxing的回复:
用了啥?webservice还是wcf?反正就是远端服务无法访问,从两方面检查1.地址是否写对2服务是否开启
服务开启了的。
解决方案五:
你连TryConnected()方法里边哪条语句抛出的异常都不知道、都不能调试,谁知道你连接远程服务的具体语句是怎样写的呢?
解决方案六:
你在catch当中写了几行代码,那么为什么还要保留try部分的代码?为什么要写try...catch呢?为什么又给注释掉了呢?注释掉的语句后边的代码难道是你有重新copy那个隐藏的什么TryConnected方法的里边的代码?难道让人瞎猜你的TryConnected里边的代码是怎样写的?
解决方案七:
谢谢。这些我不清楚,这是上一个工程师写的,已经离职了。