I add behavior extension in web.config:
<extensions>
<behaviorExtensions>
<add name="WebAppBeaviourElement" type="WebApp.Extensions.CustomBehaviorExtensionElement, WebApp.Extensions, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" />
</behaviorExtensions>
</extensions>
<behaviors>
<endpointBehaviors>
<behavior name="WebAppBeaviour">
<WebAppBeaviourElement />
</behavior>
</endpointBehaviors>
</behaviors>
But in Visual Studio 2010 is bug - WebAppBehaviourElement is not visible by visual studio and get error:/
So I think that it is possible to add this extension to endpointBehaviours in code ? And when in code I should do it?