Search code examples
asp.netvisual-studiodebuggingvisual-studio-debugging

Trying to debug .net website with Visual Studio


I've a working .Net website, I get the code from the server and copy/past it to my computer and it's runing fine on localhost with IIS.

My issue comes when I want to debug it from visual studio. When I run it, it gives an URL like : http://localhost:1390/myWebsitte/Default.aspx or it should be like : http://localhost:1390/Default.aspx. Then the path for css, script and so on are not right any more...

How can I configure my website to get the right URL and be able to debug it?


Solution

  • You should be using relative path in your ASP.NET application. Use ~/App_Themes instead of /myWebsitte/App_Themes