1

IIS Express server is not starting and throwing the following error.

The following error occurred when trying to configure IIS Express for project <project_name>.
Filename : redirection.config
Error: cannot read configuration file

I have reinstalled IIS Express server, removed and installed all the packages and even repaired visual studio. But nothing worked.

I removed .VS folder, even this didn't worked :-(.

2
  • Not a direct fix to your issue, but if you are only trying to debug you can choose to run your webapp through it's built host without IIS Express, use the drop down on the Start debug button to select the app name, usually below "IIS Express" option Commented Jun 22, 2020 at 13:23
  • Yeah, I have done this and it works fine with Project Profile, but I'm not getting why IIS Express is failing. Where are these config files located? Commented Jun 22, 2020 at 13:25

1 Answer 1

6

I got the fix, I don't know how my %userprofile% directory has two Documents named folder. Really Strange. I have no idea why there were two folders with exact name "Documents".I copied IISExpress and Mysites folders from Second Documents Folder to First Documents folder, And it worked.

Edit: Those Documents folders were actually not in same folder there were in

  1. C:\Users\<username>\Documents
  2. C:\Users\<username>\OneDrive\Documents
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.