Click here to Skip to main content
15,892,965 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
When I browse my website following error is displayed.i want to browse the pages from subfolder,and I have only one web.config file ,still it gives following error,pls help me

Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

Source Error:

Line 68: ASP.NET to identify an incoming user.
Line 69: -->
Line 70: <authentication mode="Windows">
Line 71: <!--
Line 72: The <customerrors> section enables configuration
Posted
Updated 4-Mar-11 0:43am
v4
Comments
luisnike19 4-Mar-11 9:22am    
Do you have IIS 7?

Generally this happens when you have more than one Web.Config file in your application root folder.
Just check if you have more than one. If so, remove the duplicate copies.

Read a similar issue resolved here:ASP.NET 2.0 & "allowDefinition='MachineToApplication'" error message[^]

Other useful link that has similar issue discussed: http://forums.asp.net/p/769696/769696.aspx[^]
 
Share this answer
 
Sometimes this is because you haven't configured the virtual directory to be an application

* Open IIS
* Expand {Machine Name} -> Web Sites
* Find the virtual directory for your application]
* Right mouse on virtual directory -> properties
* On the 'Virtual Directory' tab, make sure there is an entry for 'Application Name'
* On the 'Asp.Net' tab, make sure the version is correct for your application
 
Share this answer
 
For IIS 7 is propably that you need to convert the Directory to Application in case you already have a web.config in your folder.

Open IIS
Go to your website, expand
Properties in your directory
Convert to Application
Select an application pool check the version is correct according with your application.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900