Last post Jan 24, 2008 02:45 PM by Ted C
Jan 24, 2008 01:09 PM|Ted C|LINK
ASP.NET runtime error: 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.
This occurs as part of a standard ASP.NET web application with a subdirectory named Mobil in which I put mobile web forms. I wanted to have the mobile web forms part of the same application because I want it to be easy to refer to the Access database in
the application's App_Data directory.
Is there a simple solution to this error?
Jan 24, 2008 01:57 PM|podi|LINK
Did you try
Jan 24, 2008 02:07 PM|Ted C|LINK
Where does such a backup Web.config file live? I didn't create it myself, so I don't know where it would be.
Jan 24, 2008 02:15 PM|podi|LINK
Try to navigate to your application folder and check manually
Jan 24, 2008 02:23 PM|Ted C|LINK
I only see one web.config file, and I don't see anything that looks like a backup of it.
Jan 24, 2008 02:28 PM|podi|LINK
Are you sure you have checked this part of your error "This error can be caused by a virtual directory not being configured as an application in IIS." ?
Jan 24, 2008 02:29 PM|Ted C|LINK
I'm running this completely locally. IIS isn't even installed on this box.
Jan 24, 2008 02:45 PM|Ted C|LINK
I think I found the problem.
<authentication mode="Forms" />
<authentication mode="Windows" />
I commented out the authentication element from the subfolder's web.config file, and the application build succeeded.