1

so I was previously using VS2015 in Windows 10. I had built one simple ASP.NET MVC project and never faced any issue while running it. However, I have been using Windows 8.1 now and installed VS2019. Running the same application and been facing the error "Process with an ID of #### is not running". output says: "The program '[4560] iisexpress.exe' has exited with code 0 (0x0)." So I tried to open a new dummy ASP.NET Web MVC project to check if that works and it didn't.

Now, there are a myriad range of solutions provided all over and I have tried every last one of them. With no luck. 1. Delete the hidden .vs file. 2 Rename/ remove the IISExpress folder and its config file under documents. 3. Removed the specific code snippet from the solution .csproj file 4. Of course tried running VS as ADMIN. 5. Realised that IIS exress was not installed. So completed that. 6. Then realised that VS 2019 needed to have the IIS support for ASP.net core installed additionally, so done that.

Now I'm out of ideas. It would be really helpful if you could provide some more suggestions or work arounds for this problem.

Thanks.

Meraki
  • 33
  • 1
  • 5
  • Run IIS Express from command line https://learn.microsoft.com/en-us/iis/extensions/using-iis-express/running-iis-express-from-the-command-line and see if it can report you more about the cause. – Lex Li May 22 '20 at 21:53
  • Hi , I have tried this and been getting an error "Error occurred while reading configuration information". It tries to find the applicationhost.config under the %userprofile%\Documents\IISExpress\config folder however, there is only redirection.config in my config folder. The applicationhost.config file is in the .vs folder for my application. I have also tried to paste the file under the %userprofile%\Documents\IISExpress\config folder to check but no luck ! :( – Meraki May 23 '20 at 12:25
  • Clearly you should be patient to read through that article. `/config:` switch allows you to use a specific config file, and if IIS Express says any error on your config file afterwards, you know the config is corrupt and you need to fix it somehow. – Lex Li May 23 '20 at 13:34
  • Actually I have tried that too. And gotten the same result. If the config is corrupt then how can I fix that? – Meraki May 23 '20 at 15:01
  • Get started from the template, https://stackoverflow.com/questions/31713624/where-is-the-template-for-applicationhost-config-file-stored – Lex Li May 23 '20 at 16:05
  • Thanks, so much. This fix has allowed me to run the IIS finally! However, I have still been getting the error while running my ASP.Net MVC project. – Meraki May 25 '20 at 05:52
  • @LexLi It finally worked! Thanks for the guidance. :) – Meraki May 25 '20 at 19:34

2 Answers2

1

So, what finally worked for me were the following steps:

  1. Install IIS using this link - IIS Manager in Windows 10

  2. Run the IIS from command line by following this link - https://learn.microsoft.com/en-us/iis/extensions/using-iis-express/running-iis-express-from-the-command-line

  3. Opened VS 2019 in admin mode.

  4. Project -> (right click)Properties -> Web -> Servers -> Select local IIS from dropdown. -> Create Virtual Directory -> click ok. -> ctrl+S

  5. Run the application.
Meraki
  • 33
  • 1
  • 5
0

I was getting same issue. This problem can be resolved by explorin project directory and remove the .vs hidden folder.