I have a file that is part of a legacy web site I'm maintaining that I need to debug - step into, etc. But I can't see how to do that. The site needs to be run in IE, in Compatibility mode.
When I run the site from VS (2013) by right-clicking the "http://localhost/..." item beneath the solution and selecting "View in Browser (Internet Explorer" and then hit F12, I see on the Debugger tab the file that has been set as the Default page (the "main" page I see after logging in), but from there I don't see how to open a different file - the one I need to debug.
There are a handful of files apparently available for selection beneath the folder icon:
...but not the one I need. If I enter its name in the search box, I get, "No results found." It is beneath a pages folder, but so are those that are displayed. What makes them special? Why can I select those undesirables, but cannot select the only page I care about?
I have a file that is part of a legacy web site I'm maintaining that I need to debug - step into, etc. But I can't see how to do that. The site needs to be run in IE, in Compatibility mode.
When I run the site from VS (2013) by right-clicking the "http://localhost/..." item beneath the solution and selecting "View in Browser (Internet Explorer" and then hit F12, I see on the Debugger tab the file that has been set as the Default page (the "main" page I see after logging in), but from there I don't see how to open a different file - the one I need to debug.
There are a handful of files apparently available for selection beneath the folder icon:
...but not the one I need. If I enter its name in the search box, I get, "No results found." It is beneath a pages folder, but so are those that are displayed. What makes them special? Why can I select those undesirables, but cannot select the only page I care about?
Share Improve this question edited Mar 14, 2017 at 21:06 Andrii Litvinov 13.2k4 gold badges56 silver badges61 bronze badges asked Mar 1, 2017 at 21:53 B. Clay Shannon-B. Crow RavenB. Clay Shannon-B. Crow Raven 10.3k157 gold badges502 silver badges897 bronze badges 6- 1 What is the extension of the file you are trying to view? – NoAlias Commented Mar 8, 2017 at 21:50
- 1 .aspx; it's an ancient ASP.NET (2.0) app/site. – B. Clay Shannon-B. Crow Raven Commented Mar 8, 2017 at 21:55
- Just to be sure, did you load that page in the browser? I don't think it will show unless that ASPX page has been loaded. – NoAlias Commented Mar 8, 2017 at 22:00
- Yes, it is the "live" page when I try to find the source file. – B. Clay Shannon-B. Crow Raven Commented Mar 8, 2017 at 22:03
- Are you trying to debug back-end code of your aspx file? Or some embedded JavaScript code? – Ignas Commented Mar 14, 2017 at 18:45
1 Answer
Reset to default 6 +50I assume you have the JavaScript file you want to debug somewhere in dist. Just go to that file and write debugger;
inside the function you want to debug. The open dev tools in IE and reload the page. Initiate an action that should invoke that function with debugger (if it was not done on page load) and you will be able to debug it.