1
我有非常具體的問題。 如果我創建一個WCF服務,並且它有多個端點名稱,如何使用瀏覽器訪問該端點? 另外我怎樣才能通過添加服務參考訪問我的客戶端應用程序?如何在服務參考中使用WCF服務如果它有多個端點名稱
像我的配置代碼:
<services>
<service name="MultipleEndpoint.SampleService" behaviorConfiguration="MultipleEndpoint.SampleService">
<host>
<baseAddresses>
<add baseAddress="http://localhost:55052/SampleService.svc"/>
</baseAddresses>
</host>
<endpoint address="/basic" binding="basicHttpBinding" contract="MultipleEndpoint.ISampleService" bindingConfiguration="basicBinding" >
</endpoint>
<endpoint address="/wsHttp" binding="wsHttpBinding" contract="MultipleEndpoint.ISampleService" bindingConfiguration="wsBinding" >
</endpoint>
<endpoint address="/webHttp" binding="webHttpBinding" contract="MultipleEndpoint.ISampleService" behaviorConfiguration="REST">
</endpoint>
</service>
</services>
現在,當我試圖訪問使用
http://localhost:55052/SampleService.svc/basic or
http://localhost:55052/SampleService.svc/wsHttp
它給了我沒有找到IE標準錯誤信息頁/資源... 同時我想知道如何將這種類型的url作爲服務引用添加到我的客戶端應用程序中?