Webconfig Registration HttpHandler Error: An ASP. NET setting is detected that is not applicable in integrated managed pipeline mode.

Source: Internet
Author: User

Why does the above error occur?

There are two modes of application pool in IIS7, one is "Integrated mode" and one is "Classic mode".

Classic mode is the way we used to be in IIS 6.

If you are using Integrated mode, you will need to change the configuration files for your custom httpmodules and httphandlers to transfer them to <modules> and

There are two ways of solving this:

The first method, configure the application pool

Configure the application pool on IIS7 and change the schema of the program pool to "classic", after which everything is fine.

The second type: Modify the configuration file Webconfig

Before modification:

<Configuration>    <system.web>      <httphandlers>        <AddPath= "*.aspx"verb="*"type= "Customerhander, ClassLibrary1" />      </httphandlers>      <compilationDebug= "true"targetframework= "4.5" />      <HttpRuntimetargetframework= "4.5" />    </system.web></Configuration>

After modification:

<Configuration>  <system.web>    <compilationDebug= "true"targetframework= "4.5" />    <HttpRuntimetargetframework= "4.5" />  </system.web>  <system.webserver>    <handlers>      <Addname= "Customerhander"Path= "*.aspx"verb="*"type= "Customerhander, ClassLibrary1"Precondition= "Integratedmode" />    </handlers>    <Validationvalidateintegratedmodeconfiguration= "false" />  </system.webserver></Configuration>

The project structure is as follows:

1. Custom hander is a reference to other class libraries, so the type attribute is separated by commas, preceded by: Fully qualified class name followed by: DLL file (not including suffix name)

2. If hander is in this project,

The configuration in the Web. config file is as follows:

The type attribute is only required to fill in the class name.

Add: If you want to keep the original settings, you can set the Disable Authentication integration mode (validateintegratemodeconfiguration= "false"), which will not cause an error.

Webconfig Registration HttpHandler Error: An ASP. NET setting is detected that is not applicable in integrated managed pipeline mode.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.