Unable to start debugging on the web server
I have created a new website in IIS7 lets say http://abc.testwebsite.com this website was pointing to the physical path of my web project directory.
Than i open my project VS 2010 and change its properties using following method
than as we normally do i was just clicking play button in visual studio but i was getting an error saying "Unable to start debugger on the webserver...."
I dig around the internet and found that i am missing one very major step and that is an entry in my host file.
Actually this happens that whenever you want to create a new alias on your IIS or you want to open any alias from any other IIS which is not public but, it is in your local intranet, you must have to add an entry in your host file to pretend that you are actually accessing a public website.
Now again open your project in visual Studio and re-run the project. it will run successfully.
hope this article helped you, if yes. please do give your feedback and if not let me know on which point you got issue.
Than i open my project VS 2010 and change its properties using following method
- Right click Project in solution explorer
- go to Project Properties at the bottom of menu
- a configuration page will be opened. Select Web tab and from Servers section select radio button saying "Use Local IIS Web Server"
- in text box right under that radio button, give that URL where you have created a website pointing to your this project. Lets say, in my case i used [http://abc.testwebsite.com]
- Save the properties page.
than as we normally do i was just clicking play button in visual studio but i was getting an error saying "Unable to start debugger on the webserver...."
I dig around the internet and found that i am missing one very major step and that is an entry in my host file.
Actually this happens that whenever you want to create a new alias on your IIS or you want to open any alias from any other IIS which is not public but, it is in your local intranet, you must have to add an entry in your host file to pretend that you are actually accessing a public website.
For adding entry in host file
- Go to following path of your hard drive
:\\windows\system32\drivers\etc\ . normally as we install windows in C: drive so the path would be C:\Windows\System32\drivers\etc\
- Open Notepad and drag files named "hosts" into notepad.
- add a new entry in that file having following charcteristics
- IP website name
- lets say if i want to add http://abc.testwebsite.com] website to my host file my entry would be something like
- 127.0.0.1 http://abc.testwebsite.com
- Save the file and close the window.
Now again open your project in visual Studio and re-run the project. it will run successfully.
hope this article helped you, if yes. please do give your feedback and if not let me know on which point you got issue.
Comments
Post a Comment