I can\'t solve this problem
I suggest I have to change c:\\Windo
The problem would be your project setup to be executed in the local IIS and the URL specified not exist.
There are options you can do to fix the problem.
Option 1 : (Use IIS Express)
1.) Open you web project .csproj file as XAML or in notepad.
2.) Find these properties and set according to your preferences.
UseIIS = false
UseIISExpress = true
and that's it.
Option 2 : (Use local IIS)
Follow the option 1 steps but change the following properties.
UseIIS = true
IISUrl = https://localhost
UseIISExpress = false
I wanted open an exiting project of Visual Studio 2017 in VS 2019 and encountered with the same issue. I find its a version related problem. The solution is: Create a new project in the newer VS and copy the codes from the older VS.
My issue was with Windows 10 Defender. I had given IIS permission in the past, but seems like it is now ignoring it. Will look into it later, but for now I disabled controlled folder access and it worked.
The issue can be fixed by deleting the folder named .vs in the project directory.
This solves the problem because while opening the project after deleting the .vs file, it creates the same folder with subfolder config and folder with project name.
The config folder applicationhost contains the necessary settings required to run the project successfully.
More often than not, at least in my case, this happens is when a *.csproj.user
file is in the project directory and has <UseIISExpress>true</UseIISExpress>
in it.
Alternatively, as mentioned by Zachary Cutler you can also simply: close Visual Studio, delete the
*.csproj.user
file and reopen Visual Studio. This will force VS to rebuild the file.
Try decrypting the applicationhost.config file. That worked for me.