Autodocs Error: Extension element 'autodocsBehaviorExtension' cannot be added to this element.


  • Hi, 

    I have been looking for a solution to this problem without much luck. I am adding a extensions to my web.config as described there:  but got the following error: 

    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. 

    Parser Error Message: An error occurred creating the configuration section handler for system.serviceModel/behaviors: Extension element 'autodocsBehaviorExtension' cannot be added to this element.  Verify that the extension is registered in the extension collection at system.serviceModel/extensions/behaviorExtensions.

    Parameter name: element

    Am I missing a reference?  I have tried to GAC the Autodocs assembly but still no luck. What could explain this problem?  

    Thank you, 




    Here is an extract of my web.config:




            <add name="autodocsBehaviorExtension" type="Autodocs.ServiceModel.Web.AutodocsBehaviorExtension,Autodocs.ServiceModel.Web, Version=, Culture=neutral, PublicKeyToken=ad2dc2e36787b789"/>




        <!--For debugging purposes set the includeExceptionDetailInFaults attribute to true-->



            <behavior name="defaultBehavior">

              <serviceMetadata httpGetEnabled="true" />

              <serviceDebug includeExceptionDetailInFaults="true" />




            <behavior name="restBehavior">


              <autodocsBehaviorExtension/> <!-- this is the error -->




    -- jagaurg
    Monday, October 24, 2011 2:13 PM


All replies