Posts
1147
Comments
891
Trackbacks
1
Visual Studio Build Error: Error to use a section registered as allowDefinition='MachineToApplication' beyond application level

I get this from time to time, and though it is commonplace to me now, I thought I’d blog it just in case I forgot.

Sometimes you try to build your web application and you get this error.  And you haven’t been doing anything with your web.config file, so you know it has nothing to do with that.

Delete the “obj” folder from your solution (it might be hidden since it isn’t technically part of the solution).  For some unknown reason, this causes this error to occur.  Deleting the folder clears the error.

Update: I’m not sure it is the only scenario, but it happens often after publishing.  FWIW.

posted on Saturday, May 31, 2014 3:16 PM Print
Comments
No comments posted yet.

Post Comment

Title *
Name *
Email
Url
Comment *  
Please add 4 and 7 and type the answer here: