2012-10-11 46 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沒有終點設置本身。

相關問題