ASP.NET 2.0 & "allowDefinition='MachineToApplication'" error message

So, I upgraded an existing ASP.NET (1.1) application today to ASP.NET 2.0.  The upgrade had some warnings which seemed unimportant but it didn't matter since I had elected that the upgrade wizard make a backup of my application. 

Alas when I try to run the application I ran into this problem:  "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. "  I checked to ensure I had the virtual dir setup to be an application and it was...reverting back to the 1.1 version worked fine...re-upgrade and I get the problem again.

What gives?

Turns out that the VS.NET 2005 was complaining about a configuration section within the web.config file in the Backup folder of my application...just remove (ore move) the backup folder so it doesn't have a web.config file under the Virtual directory that your ASP.NET 2.0 application is running in. 

So, the "backup" option I selected on the upgrade wizard is what did me in.  :) Fun times!

Comments