Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IIS is trying to access the wrong web.config

So first a bit of background: I rechecked out my SVN repository to a new location and tried to run the application from there. And now Visual Studio is having problems launching my MVC application using Local IIS Web server. I am currently getting this error:

The requested page cannot be accessed because the related configuration data for the page is invalid.

Detailed Error Information: Module IIS Web Core Notification Unknown Handler Not yet determined Error Code 0x80070003 Config Error Cannot read configuration file Config File \?\C:\RND\app\web.config Requested URL https: //localhost:44304/app Physical Path
Logon Method Not yet determined Logon User Not yet determined Request Tracing Dir

And the problem is that the config file does not exist at c:\RND\app\web.config it is now located at c:\RND\appTest\web.config.

Is there a way I can update this in Visual Studio?

It is as if it has saved the old path somewhere and not automatically updating it.

like image 208
user1434177 Avatar asked Feb 21 '13 22:02

user1434177


1 Answers

You can correct this behavior by simply deleting the .vs file located in your project, and rebuilding the project. Visual Studio will regenerate another .vs file with the path to the web.config corrected. There are stored the settings about the web.config file path, among the others.

like image 120
meJustAndrew Avatar answered Oct 03 '22 13:10

meJustAndrew