On the surface, this looks a lot like I want to use iis 7 instead of iis express in visual web developer 2010, or Visual Studio USE LOCAL IIS WEB SERVER issue with IIS 7.5.
But, my problem is that there is no entry in applicationhost.config for this application and there is no application under IIS pointing to this project.
Plus, when I change the URL on the "Project Url:" under the project properties -> web tab, I get the same error - no matter that I type in.
Complete Original Error message (note, changed to MyServer.com because link could not point to LocalHost)
[Unable to create the virtual directory. The site for the URL 'http://MyServer.com/MyTestProject' exists on both the local IIS web server and the IIS Express web server. You need to edit the 'C:\Users\XXXXX\Documents\IISExpress\config\applicationhost.config' file to change the port number in use by IIS Express, or use IIS Manager to change this site's binding(s) in IIS.]
I can change this to 'http://MyServer.com/SuperLongRandomName10985486' and I still get the same error, but now with the new url.
And, yes, I am running VS as administrator
Something seems "stuck"
An important difference is the way worker processes are managed. In IIS, the Windows Process Activation Service (WAS) silently activates and deactivates Web applications and the user has no direct control. In IIS Express, there is no WAS and the user has full control of application activation and deactivation.
Try deleteing applicationhost.config
or move it to a different folder, worked for me.
In my case the problem was that the project was set up to start on IIS local by another developer.
Close the solution
Delete the files in your C:\Users\<username>\Documents\IISExpress\config
directory.
Open the solution
Edit the ****.sln file in NotePad and change the following setting to FALSE
<UseIISExpress>false</UseIISExpress>
(There will be multiple instances.)
As soon as I did this my project loaded just fine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With