My question was previously closed because someone said it duplicated this, How do you debug classic ASP? But that doesn't resolve my issue. The suggestions on that page I've already tried as documented in my original question.
I'm trying to debug a Classic ASP website, run by IIS, using Visual Studio 2019.
My site has these "Debugging properties" set to true:
- Calculate Line Numbers
- Catch COM Component Exceptions
- Enable client-side debugging
- Enable server-side debugging
- Run On End Functions Anonymously
- Send Errors To Browser
In Visual Studio I go to File > Open > Web Site, choose local IIS, and select my website.
In Visual studio I select Debug > Attach to Process and select the "w3wp.exe" process which is used by my website. The "Attach to", which is set to "Automatically determine the type of code to debug" detects the site as "Automatic: Native Code". I click "Attach", and "Attach" in the popup. In Solution Explorer there is only the original IIS code showing, it doesn't open a second set of the same ASP files (which it always has in the past for me before my Windows reinstall). I also tried setting "Attach to" to "Script", but that gives an error when I try that.
Now if I set a breakpoint in Visual studio the break point when you mouse over says it won't be hit because symbols are not loaded. When I put "<% stop %>" in my code, when Visual Studio is not attached, I'm not prompted to open Visual Studio, and exceptions don't cause Windows to prompt me to open Visual Studio.
It's acting as if the website doesn't have "Enable server-side debugging" enabled. I tried turning it off then on again to no avail.
Thoughts?
I've re-installed windows within the last few weeks. Before the re-install (with the same hardware and setup, software versions, etc) the above steps worked to debug code without issue.