Ryan
Ryan

Reputation: 5546

I try to run some samples in VS

Error 1 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. C:\Users\rzv\Desktop\WebSamples\Backup\WebSamples\Web.config 49

when I try to run http://weblogs.asp.net/scottgu/archive/2008/11/24/new-asp-net-charting-control-lt-asp-chart-runat-quot-server-quot-gt.aspx in VS 2010. What's wrong and why do I get IIS error when I run something in VS?

Upvotes: 0

Views: 105

Answers (1)

mellamokb
mellamokb

Reputation: 56779

Edit

When you convert a project from VS 2008 to VS 2010, it creates a folder /backup/ inside of the application. When you run the project, it is trying to run the project and the subfolder /backup/, which contains a web.config file. Move the /backup/ folder to another location and it should work.

In general, you can't run an application from a subfolder of another application if it uses application-level settings in its configuration file web.config.

Upvotes: 1

Related Questions