ASPX page within a .aspx page with iframe throws 500.23 error


I'm trying to embed a ChartModule.aspx page within a Default.aspx page using an iframe.

The ChartModule has a button event which updates a chart. The ChartModule has its own ChartsModule.cs.

I'm getting this error:

HTTP Error 500.23 - Internal Server Error An ASP.NET setting has been detected that does not apply in Integrated managed pipeline mode.Most likely causes:

•This application defines configuration in the system.web/httpHandlers section. Things you can try: •Migrate the configuration to the system.webServer/handlers section. You can do so manually or by using AppCmd from the command line. For example, from the IIS Express install directory, run appcmd migrate config "Default Web Site/". Using AppCmd to migrate your application will enable it to work in Integrated mode. It will continue to work in Classic mode and on previous versions of IIS. •If you are certain that it is OK to ignore this error, it can be disabled by setting system.webServer/validation@validateIntegratedModeConfiguration to false. •Alternatively, switch the application to a Classic mode application pool. For example, from the IIS Express install directory, run appcmd set app "Default Web Site/" /applicationPool:"Clr4ClassicAppPool". Only do this if you are unable to migrate your application.

Detailed Error Information: Module ConfigurationValidationModule Notification BeginRequest Handler
PageHandlerFactory-Integrated-4.0 Error Code 0x80070032 Requested URL http://localhost:4161/Default.aspx Physical Path
C:\Documents and Settings\singhm\Desktop\Temp\Trial2\Trial2\Default.aspx Logon Method Not yet determined Logon User Not yet determined Request Tracing Directory

Why is this?
asked on Stack Overflow Jan 18, 2012 by user849953 • edited Jan 19, 2012 by Kev

3 Answers


While this may not answer your question directly, here is a thought:

If you have the option, consider turning ChartModule.aspx into a UserControl (ascx), which acts just like another "page" (same lifecycle, its own codebehind file, etc) but integrates more cleanly into an existing aspx page. The above link should be a good introduction to creating and using UserControls.

answered on Stack Overflow Jan 18, 2012 by kaveman

The error message contains a clue to the solution:

setting system.webServer/validation@validateIntegratedModeConfiguration to false

So make sure the following is present in your web.config:

<validation validateIntegratedModeConfiguration="false"/>

For example:


  <!-- your existing settings -->


    <!-- Add this to here.... -->
    <validation validateIntegratedModeConfiguration="false"/>


IIS 7 and ASP.NET are quite helpful these days with regard to to error messages and hints contained therein so you should take the time to read them.

answered on Stack Overflow Jan 19, 2012 by Kev

I would really recommend using a usercontrol page instead of iframes in this way you can bind that usercontrol by doing

public override DataBind()

in that you can pass anything into that usercontrol page like refresh data, load certain data, etc..

answered on Stack Overflow Jan 18, 2012 by Andres

User contributions licensed under CC BY-SA 3.0