"Process with an Id of #### is not running" in Visual Studio
Asked Answered
M

53

358

I am trying to run any program on visual studio 2013 update 3 and I get the following alert box:

Process with an Id of #### is not running.

Every time there is different ID number showing.

and in the error windows, I get this error message:

The program '[3148] iisexpress.exe' has exited with code -1073741816 (0xc0000008) 'An invalid handle was specified'.

Sometimes it runs and in the browser I get the following message:

The webpage is not available.

Why is this occurring and how can I resolve it?

Monometallism answered 17/10, 2014 at 12:19 Comment(0)
C
112

First Error

For the first error:

Process with an ID #### is not running.

The following steps worked for me:

  1. Close all instances of Visual Studio.
  2. Rename the IISExpress folder (in my PC is in C:\Users\jmelosegui\Documents).
  3. Add the _CSRUN_DISABLE_WORKAROUNDS Environment System variable with the value of 1. enter image description here
  4. Start Visual Studio in administrator mode. (In Windows, right click the executable file and select Run as administrator).

Second Error

The second error:

The webpage is not available

What caused this error:

I deleted IIS Express Development Certificate while playing with the SSL.

The following steps worked for me:

  1. Go to Control Panel.
  2. Select Add/Remove Programs.
  3. Locate IIS 8.0 Express.
  4. Right click on it then click Repair.
  5. Your certificate should be back!
Claybourne answered 26/11, 2014 at 17:20 Comment(11)
I had to do the above, AND turn my computer off and on again (not just restart VS).Glasswork
I simply renamed the IIS Express folder to something else. I didn't have to add the CSRUN variable. Step 1 & 2 was all I had to do.Crespo
In regards to "Process with an ID #### is not running" error, i did not need to change any environment variables to solve this issue. I would try resolving this without the 3rd step.Nubianubian
Just renaming the IISExpress folder did it for me. There must have been something in the config that was borked.Gracye
I tried several options and the only one that worked is this one. IISExpess is recreated after doing this but I don't see any difference between both configurations.The difference is ./vs/applicationhost.config file is completely rewritten but it looks more like organization instead of something special. Looks like the variable does the trick.Thermo
One or two steps are missing in this. Please check the following url too. ryadel.com/en/process-id-not-running-visual-studio-2015-fixSidero
Works good with Visual Studio 2015. First two steps itself. Didn't have to go to the next line - The following steps worked for me: Close all instances of Visual Studio. Rename the IISExpress folder (in my PC is in C:\Users\jmelosegui\Documents).Arraign
Did you suggest that I should be running vs as admin from now on?Karyolysis
C:\Users\myusername\Documents had an IISExpess, but renaming it didn't fix the issue. Then I realized actually there's another IISExpess folder in C:\Users\myusername\OneDrive\Documents where Documents was not in English, but in my system language - Russian, while there was yet another folder 'Documents' in English. Deleting the folder did it for me.Ecclesiology
For me other way worked: I removed the web project from solution and closed VS and re-opened it. the added project again to solution. this solved my problemAstigmatism
There doesn't seem to be an official source for "_CSRUN_DISABLE_WORKAROUNDS". I think it's voodoo nonsense that does nothing at best.Ostensible
Y
520

The following steps fix the problem for me:

  • Close Visual Studio
  • Navigate to the folder where your solution files are stored and delete the hidden .vs folder.
  • Restart Visual Studio
  • Hit F5 and IIS Express should load as normal, allowing you to debug.

Note: Based on my experience and others in the comments, this problem seems to be caused by moving a project between workstations, environments, or versions of Visual Studio. There must be some environment specific information contained in the .vs folder.

Yamada answered 26/9, 2016 at 16:48 Comment(7)
this is a great way to destroy a projectStrove
@Strove how so? It might get rid of certain user settings and customizations but no code will be broken. Nothing you might have in version control would change. The .csproj remains intact. Plus, if it's in such a state that you cannot debug anyway, you've not got much to lose.Yamada
This basically worked for me for VS2017, but I was able to get away with just deleting the applicationhost.config file inside the vs folder in case this helps someone.Mccreery
I am using VS2017 and just by deleting the file /.vs/<your-project>/DesignTimeBuild/.dtbcache I got it back on track. This avoids the whole .vs folder deletion which clears some VS2017 settings.Lor
This worked for me but in combination with removing IIS Express folder as wellErring
Not only does this answer still work now, it even worked for a whole different kind (Blazor) project.Hideaway
Downgrading Visual Studio from 17.6 to 17.5 causes this issue. Deleting the .vs, obj, and obj did the trick. ThanksDisfrock
O
375
  1. Open Visual Studio as an administrator

  2. Right-click your project and click on 'Unload Project'

  3. Again, right-click your project and click on 'Edit PROJECT_NAME.csproj'

  4. Find the code below and delete it:

     <DevelopmentServerPort>63366</DevelopmentServerPort>
     <DevelopmentServerVPath>/</DevelopmentServerVPath>
     <IISUrl>http://localhost:63366/</IISUrl>
    
  5. Save and close the file .csproj

  6. Right-click your project and reload it

Optician answered 7/11, 2015 at 11:47 Comment(10)
None of the other solutions worked for me but this. Doing the above will allow iis express to re-assign an open free port to run the web page in. Note: I wasn't able to rename the IISExpress folder because it said it was in use by myself (maybe a pc restart would have fixed it?).Insufferable
This worked for me with one extra step - after reloading the project I also had to right-click on it again and select "Set as StartUp project" before it would run.Joktan
dotnet core projects do not have these settingsMajka
This works because it assigns the project a new port number. Using the previous port number will likely still fail. Your original port is locked up by another service.Rebozo
For me it was enough to unload and reload the project.Eada
This didn't work for me, I don't have DevelopmentServerPort in my csprojKickback
In addition to this I had to go to the project Properties > Web and change the Start Action otherwise I was getting a Connection Error as it was attempting to navigate to the wrong port number.Blockbuster
I tried most of the solutions out there and this one did it for me! Thank you @aliKiushu
The settings can be found in the [projectName].csproj.user file, too. Could you add this in your answer?Felicific
I wonder why you cannot change the port back to the original once all is running? Is there a registry setting or hidden (in .vs?) configuration setting where the original port number is stored or something? Sigh ... And yes, for us, this occurs after copying a whole project, including solution and project files, onto another development PC.Subsume
C
112

First Error

For the first error:

Process with an ID #### is not running.

The following steps worked for me:

  1. Close all instances of Visual Studio.
  2. Rename the IISExpress folder (in my PC is in C:\Users\jmelosegui\Documents).
  3. Add the _CSRUN_DISABLE_WORKAROUNDS Environment System variable with the value of 1. enter image description here
  4. Start Visual Studio in administrator mode. (In Windows, right click the executable file and select Run as administrator).

Second Error

The second error:

The webpage is not available

What caused this error:

I deleted IIS Express Development Certificate while playing with the SSL.

The following steps worked for me:

  1. Go to Control Panel.
  2. Select Add/Remove Programs.
  3. Locate IIS 8.0 Express.
  4. Right click on it then click Repair.
  5. Your certificate should be back!
Claybourne answered 26/11, 2014 at 17:20 Comment(11)
I had to do the above, AND turn my computer off and on again (not just restart VS).Glasswork
I simply renamed the IIS Express folder to something else. I didn't have to add the CSRUN variable. Step 1 & 2 was all I had to do.Crespo
In regards to "Process with an ID #### is not running" error, i did not need to change any environment variables to solve this issue. I would try resolving this without the 3rd step.Nubianubian
Just renaming the IISExpress folder did it for me. There must have been something in the config that was borked.Gracye
I tried several options and the only one that worked is this one. IISExpess is recreated after doing this but I don't see any difference between both configurations.The difference is ./vs/applicationhost.config file is completely rewritten but it looks more like organization instead of something special. Looks like the variable does the trick.Thermo
One or two steps are missing in this. Please check the following url too. ryadel.com/en/process-id-not-running-visual-studio-2015-fixSidero
Works good with Visual Studio 2015. First two steps itself. Didn't have to go to the next line - The following steps worked for me: Close all instances of Visual Studio. Rename the IISExpress folder (in my PC is in C:\Users\jmelosegui\Documents).Arraign
Did you suggest that I should be running vs as admin from now on?Karyolysis
C:\Users\myusername\Documents had an IISExpess, but renaming it didn't fix the issue. Then I realized actually there's another IISExpess folder in C:\Users\myusername\OneDrive\Documents where Documents was not in English, but in my system language - Russian, while there was yet another folder 'Documents' in English. Deleting the folder did it for me.Ecclesiology
For me other way worked: I removed the web project from solution and closed VS and re-opened it. the added project again to solution. this solved my problemAstigmatism
There doesn't seem to be an official source for "_CSRUN_DISABLE_WORKAROUNDS". I think it's voodoo nonsense that does nothing at best.Ostensible
P
24

With respect to the first error:

Process with an ID #### is not running

This situation will sometimes occur when IIS Express fails to bind to a port. A likely reason for that is that some other process has already bound to that port. Visual Studio will launch the IISExpress.exe process (which will fail to bind to the port and exit again) and then attach to the now-terminated process, resulting in the above error.

To check, note the port number in your project settings (e.g. 12116) and then try:

netstat -ano | find "12116"

If another process has the port open, this will give its PID. You can then choose to kill the offending process or reallocate your own port number.

Preconcert answered 10/5, 2015 at 12:48 Comment(0)
M
21

My fix was simple, I was missing prerequisites. I needed to install .NET Core SDK

Minnesinger answered 15/11, 2021 at 11:28 Comment(5)
Me too, I had an old project targeting "netcoreapp2.2" in my csproj, found the installer online (wasn't listed on the VS installer because it's EOL) and the project ran immediately.Ladida
This happened to me as well, even though I'd run the project before and didn't see any changes in the .csproj or .sln files - VS/msbuild suddenly started requiring the latest SDKHarem
me too, I had net6 SDK installed but the app was built on net5Chary
This solved my problem also. I had net core 6 and the project required net core 5.Freitag
Godo answer! This was my problem too (I hadn't installed the .NET 3.1 runtime). The error is not very clear!Religieux
B
20

If you are using a 64-bit machine

Then the problem maybe due to Visual Studio use of 32-bit IIS-Express.

Solution: In Visual Studio, go to Tools menu > Options > Projects and Solutions > Web Projects > Enable the option "Use the 64 bit version of IIS Express" and click ok

Bettis answered 26/5, 2015 at 9:51 Comment(4)
You'd think it would use the 64 bit version by default.Dissatisfied
Only discovered after checking the version of my OS that it is 64-bit That was the cause all along.ThanksPark
I still got the error after activating this.Christean
For my case was the opposit, I have to uncheck this and it worked. I think because I use windows on Mac M2 with ParallelsSuannesuarez
C
15

I had the same problem. Just restarting Visual Studio worked for me.

Cymoid answered 26/2, 2015 at 16:57 Comment(2)
If more than one instance of VS running, it seems they must all be closedEnfold
Tried all the solutions mentioned, nothing worked. Restarting the PC did the trick.Menhaden
H
15

Another reason this can happen is for a .NET Core Web app if you upgrade the Microsoft.AspNetCore.Components.* NuGet package to a new version but don't install the new SDK,

In my case it was upgrading Microsoft.AspNetCore.Components.WebAssembly from 6.0.0 to 6.0.1 and didn't install .NET 6.0.1 SDK

Hann answered 11/1, 2022 at 23:25 Comment(4)
This is what happened to me. I received this error immediately after upgrading the MS nuget which was expecting the latest version of .NET Core.Arbutus
Also happened to me.Willner
Same here. I am happy I have found this so fast.Request
same here, I tried to start an old .netcore 3.1 app but the framework was no longer available on my machine... Had to upgrade to .net 8 and it worked again :)Fescue
L
12

In my case, I run this command to get the real error:

dotnet run --project Project\MyProject.csproj

Then I see this error: enter image description here

I just installed the new version of dotnet and the error is gone.

Lundt answered 17/11, 2023 at 12:54 Comment(3)
This approach worked for me. I had the same problem.Pyrolysis
In my case, I need to install an old version of .NET to make an old project to work.Nourishment
IN 2024 This is the wayArk
L
9

Kilanny's answer is correct. Most machines in 2015 are 64bit, so there's a lot of chances that you just need to enable the 64bit option under the Tools main navigation link menu. No need to configure other files or hard code ports. Besides, port assignment should be dynamic. This fix applies to 2013 With Update 3 and Visual Studio 2015 Community Edition.

Check the images below for a mini tutorial: (I'm just improving Kilanny's answer)

Visual Studio Tools Menu

Visual Studio Web Project Options

Logy answered 8/10, 2015 at 17:1 Comment(1)
I've had this setting enabled for a couple weeks and the solution for me was to turn this off.Tindall
B
8

It looks like there are many solutions that work and some that don't...

My issue kept surfacing after a few test iterations. Yes restarting the PC and/or VS would resolve the issue...but temporarily.

My solution was to undo a security change I had enabled a couple days earlier to Controlled folder access under Ransomware protection.

I undid this change by:
(right click Start) Setting->Update & Security->Windows Security->Virus & threat protection-> Virus & threat protection settings->Manage settings

Under Controlled folder access Click->Manage Controlled folder access (this is also the Ransomware protection screen)

Turn Controlled folder access off.

This was 100% the issue for me as I was able to run my test without restarting VS.

Bathysphere answered 15/4, 2019 at 16:41 Comment(3)
I know you answered a long time ago, but your solution has finally resolved my issue. After playing around with all the other "solutions", turning off Controlled folder access resolved the issue. I took this one step further and instead of totally turning this off, I clicked the Allow an app through Controlled folder access and added an allowed app, selecting iisexpress.exeMandrel
A further note on this - you can be a bit more granular and just add IIS Express to the "allowed apps" in ransomware protection.Mumbletypeg
@Mumbletypeg I'm gonna revisit this after your comment ...I did notice that I has added ISS Express that last time! I'm going to recreate the problem and see if I can nail it down a little more.Bathysphere
P
5

I had a similar problem with Chrome. It appears that VS can't attach to the Chrome process for some reason.

Solution:

  1. Close Chrome
  2. With Chrome closed, start the web project and allow VS to open Chrome.
Phototransistor answered 21/4, 2015 at 16:16 Comment(0)
T
5

My solution to this on a new machine and fresh install of VS 2022 was to install the 3.1 framework. So check to make sure whatever framework the project is expecting is installed on your local machine.

Transhumance answered 14/12, 2021 at 15:28 Comment(0)
M
4

go to Properties of the start up project, increment port number of the Project Url is probably the quickest way to get around this problem which I didn't read anyone mentioned yet.

And you don't need to restart VS as it can be a pain sometimes if you needed a few other instances needed to be running.

Marucci answered 9/1, 2017 at 11:49 Comment(0)
E
4

I had the same problem, and what needed to be done was setup IIS Express properly.

I right clicked on my project Properties => Web (tab) and on Servers: Project URL was already pre-populated and I clicked the button "Create Virtual Directory".

I had just reinstalled (refreshed) windows and the IIS was not setup b/c it was new.

Edwardedwardian answered 28/6, 2018 at 13:16 Comment(1)
This worked for me - I actually changed it to a different port number as well and then was prompted to "Create Virtual Directory". That seems to have done the trick.Aqueduct
P
4

Reboot your computer before trying any of these!

Some of these may be helpful. Doing the netstat trick

netstat -ano | find

helped me as another application was using my port, but didn't completely solve my problem. IIS Express still kept crashing. It wasn't until I rebooted my win 10 PC (first time in over a week), that my problem completely cleared up.

Perdue answered 29/4, 2020 at 21:13 Comment(2)
For me, begin by looking for the simplest, least destructive solutions first. I checked restart, and I had a pending windows update ready to install. When I updated (through restart) it then worked fine for me.Burgos
I had to do multiple reboots, eventually worked. Advice: maybe try two before trying other solutions.Templia
H
4

I encountered this while trying to run a project I'd run many times on a machine I'd used for the project many times. Cleaning up my IIS Express directory and my .vs directory didn't work, nor did setting environment variables. I even tried re-cloning my repository to a different folder, but no success.

By trying to run via command line, I found a more useful message:

dotnet run --project [startup project path]

I saw that the project was trying to run using .NET 6.0.5, but I only had .NET 6.0.4 installed. Installing the latest .NET 6.0.5 from the Microsoft website worked.

Harem answered 12/5, 2022 at 19:19 Comment(1)
Before you all trying other solutions try this. I had .net core 3.1 app and after fresh vs 2022 install i did not install unnecessary packages. I just only installed .net 6.0. But I could not open my app and it did not give me proper message. So i just install .net core 3.1 and it fixed.Melanite
S
3

For me, none of the other solutions worked. The things I tried:

  • Updating and patching everything associated with Visual Studio
  • Reinstalling Visual Studio
  • Reinstalling IIS Express
  • Several reboots
  • Adding the _WORKAROUND thing to the PATH
  • Renaming the IIS folder under documents to regenerate the IIS config
  • Manually editing the csproj file and removing the whole IIS settings section
  • Changing the IIS executable usage to 64bit in VS settings
  • Changing the port of IIS in the projects settings

After checking if the problem was persistent over different projects, it turned out that the problem only occurred in one specific projects. I figured that I had to delete all the user specific files in the solutions folder (such as bin, obj, *.suo, ...) I just deleted the whole solution folder and reverted the files in git.

TLDR: Try deleting user specific files/folders like bin, obj, *.suo, ...

Summit answered 15/7, 2016 at 13:11 Comment(0)
C
3

Head to the following directory

%userprofile%\documents\IISExpress\Config directory

Delete all files within that folder. Restart visual studio and works like a charm.

Costanza answered 16/6, 2017 at 21:6 Comment(0)
B
3

Close VS. Navigate to the folder of the solution and delete the hidden .vs folder. Restart VS. Hit F5 and IIS Express should load as normal, allowing you to debug.

If this not working, then:

  1. right click your solution and go to properties

  2. Click left menu Web tag

  3. Click checkbox "Override application root Url"

and run again your project.

Beersheba answered 3/1, 2020 at 5:38 Comment(1)
This just repeats the top answer.Murther
D
2

I also had the same problem, doing the above didn't work for me. What my error turned out to be was twofold.

  1. I had Opera as my default browser and it couldn't attach to that.
  2. I had multiple startup projects so it wouldn't let me switch to IE until I change the default startup project back to just the MVC shell.

I set that project specifically as the startup, then I switched it back to launching IE and it started debugging again.

Darleen answered 29/1, 2015 at 20:28 Comment(0)
B
2

I came across the same problem and found that somehow the file 'applicationhost.config' (in ..\Documents\IISExpress\config) had a different localhost port number (in the 'sites' section) to the one specified in project\properties\web. Changed them to the same number and the problem went away

Birdsall answered 24/2, 2015 at 17:33 Comment(0)
I
2

What I did to make this go away:

Open C:\Users\gr_mext1\Documents\IISExpress\config\applicationhost.config and remove all <site> entries in <sites> do not remove <siteDefaults>!

In your project, go to Properties, Web and click "Create Virtual Directory".

Close and re-open visual studio, load your project and run

Fixed!

Iq answered 3/12, 2015 at 12:12 Comment(1)
Only this worked for me. I removed entire IISExpress folder and that fixed the problem.Pulsatile
R
2

Tried most of the things here to no avail, but finally found a fix for my machine, so thought I'd share it:

Following previous advice in another question, I had used netsh to add :: to iplisten. It turns out undoing that was my solution, by simply replacing add in their advice:

netsh http delete iplisten ipaddress=::

You can also do this manually by deleting HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\HTTP\Parameters\ListenOnlyList from the registry and restarting the service/your PC.

Ramillies answered 5/4, 2019 at 15:0 Comment(0)
R
2

For me this was the solution,

  1. Close all running Visual studio instances
  2. Open the solution folder and remove the .vs folder (hidden folder)
  3. Open Run Command
  4. Type iisreset and press Ok, and you may see a command prompt and wait for it to complete and it will close automatically

Now Open visual studio and run your project, it should run.

Raincoat answered 2/6, 2021 at 17:42 Comment(0)
P
2

So, nothing worked for me and this happened to happen to me when I got a new machine. Apparently it didn't have the older versions of .Net on it. Went into VS Installer and checked the box for .Net 5 Runtime (VS 2022). Working fine now on all .Net 5 Projects.

Pyelography answered 4/11, 2021 at 17:16 Comment(1)
In my case this issue reproduced after I uninstalled vs 2019 and installed vs 2022, by adding .net 5 runtime the issue was fixed the issue, thx a lot !Percale
H
2

TL;DR: if you do have the right .NET Core (or .NET I guess) runtime installed, install any patch updates or reinstall the latest version if there aren't any.

Detail: Similar to a couple of other answers where they just didn't have the right .NET core installed. I was trying to run a .NET Core 3.1 web app which had worked fine previously for months, and this suddenly started happening.

I did have 3.1 (runtimes 3.1.21 and 3.1.22) installed. However a new one (3.1.23) had been released 12 days earlier, and installing that fixed the problem.

I have no idea if this was because it's aware that there's a new patch and I didn't have it so it wouldn't run, or if there was just something wrong with my 3.1.22 installation. Worth trying installing latest patch, or reinstalling existing installations.

Handbarrow answered 20/3, 2022 at 11:0 Comment(0)
R
2

In my case I had to update Visual studio 2022 from Visual Studio Installer. I was using Blazor and .Net7 and the blazor app wouldn't launch. By the way, I will add, remember to update the SDK, and the blazor if it concerns you.

Radiochemistry answered 11/5, 2023 at 11:38 Comment(0)
S
1

None of the listed solutions worked for me. Problem was some sort of conflicting state in local applicationhost.config file. Fix is easy, just delete one in your solution. For VS2015 it should be located in <path_to_your_solution>\Solution\.vs\config\. When you launch Debug, VS will recreate that file based on settings in your project file.

Sauropod answered 18/4, 2017 at 16:22 Comment(0)
A
1
cmd - regedit-HKEY_LOCAL_MACHINE-SYSTEM-CurrentControlSet-Services-HTTP-START=3

Computer restarted.

worked for me!

Aimless answered 4/7, 2017 at 12:9 Comment(0)
R
1

Deleting the hidden .vs folder didn't work for me since the port specified in my app was being used by another app. Doing the following worked for me:

  1. Went to properties and then click the web tab.
  2. Changed the port number in the Start Url and the Project URL.
  3. Clicked Create Virtual Directory.
  4. Save and Press F5.
Reduplicate answered 4/4, 2018 at 0:41 Comment(0)
K
1

I update my Visual Studio to 2019 version and has this problem, I tried all solution from this question but it doesn't help to start my ASP.NET MVC 5 project with IIS Express. After I remove IIS Express (using Control Panel), download last version from www.microsoft.com and install it. After this everything works fine.

After some weeks i got update for Visual Studio and I got this problem again. I remove IIS Express and reinstall and it works fine now. p.s. repair didn't help me, only uninstall and install.

Keef answered 14/5, 2020 at 16:34 Comment(0)
P
1

I had a similar issue, but mine was the presence of deleted image files in the drive.

I removed it, deleted .vs hidden folder, now it works

Premises answered 20/5, 2020 at 9:50 Comment(5)
What does this add over the top answer, which already instructs the user to delete the .vs folder?Murther
@TylerHcheck the accepted answer, its different.Premises
I did check the accepted answer and I don't see a difference so I am asking you, the author, to clarify what is different. The accepted answer says to delete the hidden .vs folder. This answer also says to delete the hidden .vs folder. There doesn't seem to be a difference there.Murther
@Murther check this, this is the accepted answer https://mcmap.net/q/92648/-quot-process-with-an-id-of-is-not-running-quot-in-visual-studioPremises
Sorry, the top answer, shown first when ordered by score (the default). Which is what my first comment specified.Murther
E
1

Found the solution!

I had something similar:

The main problem was Start registry entry located at:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\HTTP

The solution: change the value of Start key from 4 to 3 and reboot.


Tired the following, yet there was no success:

  1. Reinstall the whole VS2019 web development environment;
  2. Delete %userprofile%\Documents\IISExpress;
  3. Delete .vs folders;
  4. Remove IIExpress 10 from Programs in Win10;
  5. Change various project settings/properties.

One of the possible issue sources I recall is running Laragon which required to change this value to 4 in order to start an Nginx web server.

Euh answered 4/6, 2020 at 15:47 Comment(1)
This was the issue I had. I had disabled it to unblock port 80 and then a week later was completely stumped by why IIS wouldn't launch. Sadly this was on page 2 and I didn't notice it until after figuring it out. I'm upvoting so hopefully others won't suffer.Snuggle
C
1

I found the source of the problem. The source of the problem is not from my project nor from my visual studio, but from my IIS.

When I open iisexpress.exe from C:\Program Files\IISExpress, the command prompt closes immediately. If your IIS Express is fine, then what will appear is as shown below.

iisexpress.exe if success

What I do is reset or reinstall IIS Express via "Turn Windows Features on or off" in the Control Panel. And follow the step by step instructions contained in the following link

Answer to IIS w3svc error

Carport answered 15/11, 2020 at 12:29 Comment(1)
In my particular scenario changing the port sufficed. Perhaps this should be the first option before reinstalling the entire IDE.Stanfill
C
1

I ran the command :

dotnet --list-sdks

I saw I had a slightly older SDK than what I had set up inside the .csproj file. So I downloaded the latest .net 6 SDK and closed and reopened Visual Studio. The solution finally started up.

Christean answered 21/10, 2022 at 11:20 Comment(0)
W
1

Restarting Your PC worked for me. Try that first before messing with a bunch of other stuff/settings.

Wellspoken answered 28/3, 2023 at 22:12 Comment(0)
P
1

After updating all windows updates, it started working.

I think the windows update crashed it.

Premises answered 20/11, 2023 at 6:3 Comment(0)
T
1

In my case dotnet app was hitting an exception. Best way is to look at the application event log

Description: A .NET application failed.
Application: XX.Api.exe
Path: C:\XX.Api\bin\Debug\net6.0\XX.Api.exe
Message: You must install or update .NET to run this application.

App: C:\XX.Api\bin\Debug\net6.0\XX.Api.exe
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '6.0.27' (x64)

.NET location: C:\Program Files\dotnet\

The following frameworks were found:
  3.1.32 at [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  5.0.17 at [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  6.0.26 at [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]

Installing dotnet 6 fixed the issue

Tenement answered 13/2, 2024 at 23:4 Comment(1)
This was my issue -- was targeting a version of .NET SDK that wasn't installed.Garik
L
0

I recently had the same issue with VS 2013 and IIS Express:

"Process with an ID #### is not running ." // every time there is different ID number showing.

Here was the solution I found that worked for me:

1) Go into the Documents -> IIS Express -> config -> applicationhost.config

2) I opened applicationhost.config in Notepad++

3) Under the tag , there are lines of code that looks like this:

    <add name="Clr4IntegratedAppPool" managedRuntimeVersion="v4.0" managedPipelineMode="Integrated" CLRConfigFile="%IIS_USER_HOME%\config\aspnet.config" autoStart="true">
                 <processModel loadUserProfile="true" />
        </add>

4) Remove these two lines

                <processModel loadUserProfile="true" /> 
        </add>

5) Change the END of the first line to

            <add name="Clr4IntegratedAppPool" managedRuntimeVersion="v4.0" managedPipelineMode="Integrated" CLRConfigFile="%IIS_USER_HOME%\config\aspnet.config" autoStart="true" />

Notice that all I did was close the tag by adding ' /' after "true".

I am now able to run my projects in a web browser AND debug my code.

Also, I had updated to Update 4, but was having the same issue. I believe appending the applicationhost.config file was what fixed the problem.

I hope this helps!

Lollop answered 25/6, 2015 at 17:2 Comment(1)
I forgot to mention, I tried all of the other options posted on this particular question and many other I had found on other forums and sites. None of them worked.Lollop
K
0

This can happen for various reasons, helpfully - if you run IISExpress.exe (\Program Files (x86)\IISExpress\iisexpress.exe for 32-bit, \Program Files\IISExpress\iisexpress.exe for 64-bit) in the command line, you'll get some more details. In my case:

C:\Program Files\IIS Express>iisexpress.exe

Filename: \\?\C:\Users\My.Username\Documents\IISExpress\config\applicationhost.config
Line number: 15
Error: Configuration file is not well-formed XML

Nice and easy to fix, that one my was my fault though!

Kamalakamaria answered 30/10, 2015 at 13:26 Comment(0)
B
0

For me, VS uses Firefox for the default browser. Restarting VS and closing all Firefox windows seems to resolve this issue.

Bessie answered 8/3, 2016 at 21:4 Comment(1)
This is a duplicate of https://mcmap.net/q/92648/-quot-process-with-an-id-of-is-not-running-quot-in-visual-studio. There doesn't need to be a "restart VS" for every OS and browser.Claude
E
0

If you're using git as source control, you should also make sure that any user specific files are ignored.

[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/

If they're already tracked, then use git -r rm --cached

This resolved the error for me.

Essene answered 15/11, 2016 at 22:29 Comment(0)
Y
0

startMode="alwaysRunning" in $SOLUTION_DIR/bis/.vs/config/applicationhost.config caused it for me. Try to remove that string and everything will work again (even without restart of VS)

Yu answered 6/2, 2017 at 7:50 Comment(0)
W
0

Close your instance of Visual studio. Start it again in Administration mode. "Run as Admin"

Wunderlich answered 2/10, 2017 at 11:30 Comment(0)
K
0

Running as administrator didn't seem to make a difference when I got this.

  • Make sure all iisexpress.exe processes had been closed
  • Edit <path_to_your_solution>\Solution\.vs\config\applicationhost.config
  • Change the site name.

    <site name="MySite" id="1" serverAutoStart="true">

    to :

    <site name="MySite2" id="1" serverAutoStart="true">

  • That fixed it for me
Kalat answered 15/11, 2017 at 6:0 Comment(0)
V
0

What fixed it for me was running the project from a different file in my solution. Specifically, 2 of my files are named web.config, so I just ran from the other one.

Vinculum answered 21/6, 2018 at 13:16 Comment(0)
D
0

I had similar issue because of IIS Express being installed under Documents and Documents folder was synced with One Drive. Deleted .vs folder and reinstalled IIS Express. Before installing IIS Express, delete IIS Express folder after uninstall.

Diphosgene answered 27/2, 2023 at 21:1 Comment(0)
J
0

For me, I deleted the .vs folder and restarted vs, and it didn't work. After restarting my laptop it worked again.

Jurgen answered 6/6, 2023 at 10:52 Comment(0)
A
0

In my case it was missing .Net Core SDK after windows update from 10 to 11 and old version of VS uninstall (had multiple versions). It is very weird but worth a check if targeting SDK version is still there.

Aniakudo answered 7/9, 2023 at 9:35 Comment(0)
T
0

Update your dotnet SDK or install version of dotnet SDK of your project.

Tessellated answered 16/10, 2023 at 6:8 Comment(0)
D
0

In my case, others' suggestions did not work (deleting .vs folder, bin files, obj files, changing port, restarting VS etc.), but I fixed the problem by upgrading target framework from 3.1 to 7. to do this, open .cshtml file and change

<TargetFramework>netcoreapp3.1</TargetFramework>

to:

<TargetFramework>net6.0</TargetFramework>
Dyscrasia answered 19/10, 2023 at 7:50 Comment(0)
I
0

In my case problem was with docker. Pause docked fixed.

Ireneirenic answered 28/3, 2024 at 16:33 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.