2012-10-13 28 views
0

我有一個問題,我試圖克服,我走了這是可能的但我不知道如何。WCF/silverlight endpoints

我在我的服務提出了以下配置

<configuration> 
<system.serviceModel> 
    <bindings> 
     <customBinding> 
      <binding name="CustomBinding_MyDataService"> 
       <binaryMessageEncoding /> 
       <httpTransport maxReceivedMessageSize="2147483647" maxBufferSize="2147483647" /> 
      </binding> 
     </customBinding> 
    </bindings> 
    <client> 
     <endpoint address="http://mywebsite.com/vdir/Services/MyDataService.svc" 
      binding="customBinding" bindingConfiguration="CustomBinding_MyDataService" 
      contract="HBDataLayer.MyDataService" name="CustomBinding_MyDataService" />   
    </client> 
</system.serviceModel> 

的問題是終點地址,我有地址設置爲實際發佈的位置然而,當我嘗試在本地我得到調試跨域策略問題。我必須不斷更新本地主機和網站之間的配置文件切換。

我被告知可以配置它,所以你沒有這個問題。

有誰知道如何?

回答