So I inherited an IIS website and I am not familiar with the tools. When I run project it wants to start up at localhost/myApp/. If I do not have IIS configured to start up in this location then debugger fails to attach. However, I have code that assumes my site is on the root directory. I am on IIS 7 and Win 7 x64.
when I debug the website from inside VS2010 how do I tell it that my website is located at localhost/? My project is the one highlighted in red.
To debug the website using root with visual studio in a website project do the following:
The reason you can't change the starting url is because of the way the project was added to the solution. When the Web Site project is listed as a url instead of as a local file system path, it is because the project was added to the solution by using Add > Existing Web Site > Local IIS
option. When a project is added in this manner, then Visual Studio.NET will not allow you to change the path.
In order to change the path, you should remove the project from your solution and add it back to the solution using Add > Existing Web Site > File System
. Use the Add Existing Web Site dialog to navigate to the project folder (the same folder that is used as the Physical Path for the site in IIS). When the project is readded it will be listed in the Solution Explorer by the local path (i.e., E:\inetput\myapp) instead of the localhost url. From there, all of the options under Start Options should be configurable.
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