Reputation: 1400
I've inherited a c# application that I don't know much about. When I build and publish it I get the following error:
The binding at system.serviceModel/bindings/basicHttpBinding does not have a configured binding named 'BasicHttpBinding_ILan_Structure_WCFService'. This is an invalid value for bindingConfiguration.
This is the code from my web config:
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="BasicHttpBinding_ILan_Structure_WCFService">
<security mode="Transport" />
</binding>
</basicHttpBinding>
</bindings>
<client>
<endpoint
address="https://website.com/Lan_Structure/Lan_Structure_WCFService.svc"
binding="basicHttpBinding"
bindingConfiguration="BasicHttpBinding_ILan_Structure_WCFService"
contract="Lan_Structure_WCFService.ILan_Structure_WCFService"
name="BasicHttpBinding_ILan_Structure_WCFService"/>
</client>
</system.serviceModel>
I don't think I understand the error fully because I thought after a bit of Googling that it was referring specifically to this section:
<basicHttpBinding>
<binding name="BasicHttpBinding_ILan_Structure_WCFService">
<security mode="Transport" />
</binding>
</basicHttpBinding>
So I thought there was a typo here which isn't the case!
bindingConfiguration="BasicHttpBinding_ILan_Structure_WCFService"
I've tried reading these:
https://msdn.microsoft.com/en-us/library/ms733099(v=vs.110).aspx
The binding at system.serviceModel/bindings/wsHttpBinding does not have a configured binding
And I've tried removing the reference to the binding configuration as per this question:
The binding at system.serviceModel/bindings/wsHttpBinding does not have... error
But I'm a bit lost. Any help would be greatly appreciated!!! Also does anyone know where I can read a bindings for dummy's or something similar? I could do with reading up on this!
Upvotes: 3
Views: 10015
Reputation: 163
just for some one who stumbles on it. In place of
<basicHttpBinding>
use <webHttpBinding>
. This should fix the issue.
Upvotes: 1