Search code examples
javascriptasp.netwebformsnavigationascx

Navigate to the page on asp website where code is instantiated


I have found several instances of a code element that needs to be updated in our codebase.

However, it's actually difficult to navigate to the relevant code on the website opened by the debugger.

The debugger opens a browser, e.g., Google chrome, and I need to find where the page I'm trying to update the code exists. Specifically: How can I find a specific word or phrase used as a code element in a page such as an .ascx file, or a JavaScript routine. An example (one of many potential examples) would be:

MultipleCheckBoxes

on the website including its numerous subsites?

The coding folder contains a total of 2000 objects, and I am unsure of website "navigation tree" but I'm guessing there are at least dozens, possibly hundreds of pages and sub-pages.

This stack overflow question is essentially dealing with the inverse problem of going from the page to the code:

What's a good way to navigate code base and find source for a webpage


Solution

  • You cannot debug .ascx files from a browser; .ascx files are user controls that live within/are called from aspx pages in Web Forms projects; they are interpreted by the server, like .dll files, not by the client browser (even in a 'debug' mode).

    You will need to search for this content from within Visual Studio or whatever IDE you are using. Visual Studio lets you search for keywords or phrases within the current page, all open pages, the current solution, or all solutions in the current project.