2012-10-11 47 views
0

我创建了一个WCF Web服务,我从ASP.NET 1.1网站调用它。找不到引用合同的默认端点元素

我已经添加了一个简单的操作合同发送一个字符串值= IT工作。

在WCF Web服务信息

我在WCF Web服务增加了一个DLL。 我正在访问操作合同中的DLL公开方法。

但我面临当我调用的操作合同的问题:

在Web服务中我已经提到/添加这暴露出一些方法, 一个DLL和我打电话这些方法在我的一个操作合同中。 description7a.Description7aPortType =这是来自 我在WCF服务中添加的DLL。

这是给错误:

Could not find default endpoint element that references contract 
    'description7a.Description7aPortType' in the ServiceModel client 
    configuration section. This might be because no configuration file was 
    found for your application, or because no endpoint element matching this 
    contract could be found in the client element. 

我怎样才能解决这个问题? WCF Web服务

<system.serviceModel> 
    <services> 
     <service name="ADSChromeVINDecoder.Service" behaviorConfiguration="asmx"> 
     <endpoint address="basic" binding="basicHttpBinding" 
       contract="ADSChromeVINDecoder.IService"></endpoint> 
     </service> 
    </services> 
    <behaviors> 
     <serviceBehaviors> 
     <behavior name="asmx"> 
      <!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment --> 
      <serviceMetadata httpGetEnabled="true"/> 
      <!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information --> 
      <serviceDebug includeExceptionDetailInFaults="true"/> 
     </behavior> 
     </serviceBehaviors> 
    </behaviors> 
    <serviceHostingEnvironment multipleSiteBindingsEnabled="true" /> 
    </system.serviceModel> 
+0

被引用的DLL似乎在使用另一个WCF服务,并且期望web.config文件中的端点配置。检查引用的DLL的文档以及如何使用DLL提供的功能的要求。 – jags

回答

0

添加由DLL使用的Web服务的一个服务引用

WEB CONFIG没有终点设置本身。

相关问题