"UWPHost.pdb not loaded" - Debugging Xamarin UWP app - visual-studio

I have a Xamarin app for which I have been debugging the UWP app on my computer for testing.
I've been having difficulties debugging. I keep getting a 'No Symbols Loaded' error which goes onto say one of the following errors:
UWPHost.pdb not loaded
or
wkernelbase.pdb not loaded
Typically, restarting or rebuilding Visual Studio will sometimes resolve the issue temporarily. As a result of this, development has been an incredibly painful process.
Any idea how this sort of problem can be avoided?
Additionally, if it's not the PDB errors I get this instead:
Unable to activate Windows Store app ... 'The app didn't start'
These errors can happen with absolutely zero changes.
I'm new to Xamarin so I could be missing something blindingly obvious here.
Something I already tried was checking the 'Microsoft Symbol Servers' option via Visual Studio options.
I'm using Visual Studio 2019.
UPDATE:
I changed the following Visual Studio option:
Tools -> Options -> Debugging -> General -> Enable .NET Framework source stepping
This allowed me to see the following error:
Unhandled exception at 0x7747C762 (KernelBase.dll) in Framework.UWP.exe: 0xE0434352 (parameters: 0x8007000B, 0x00000000, 0x00000000, 0x00000000, 0x03B40000). occurred

Related

I recently updated to Visual Studio 16.5.0 Preview 2.0 and I'm getting a fatal error when debugging an Azure Function project

I recently updated to Visual Studio 16.5.0 Preview 2.0 and I'm getting the following error.
I'm trying to debug a project for an Azure Function. Has anyone encountered this before?
A fatal error has occurred and debugging needs to be terminated. The
debugger was configured to use the desktop CLR (.NET FRAMEWORK)
Managed debugger, but the target process loaded the CoreCLR (.NET
CORE) runtime. To debug this project, configure it to use the 'Managed
(CoreCLR)' debugger.
Here is a similar issue about this.
Please try follow the steps to configure it to use the 'Managed (CoreCLR)' debugger.
In Visual studio -> Debug menu -> Attach to Process -> in "Attach to" field, click the "select" button -> then in the "Debug those code types", select "Managed (CoreCLR)".
The screenshot as below:

Debugger error "Unable to attach. Invalid Pointer" from Ripple

I've just installed the Multi-device Hybrid Apps preview for Visual Studio 2013, and I'm getting an error when attempting to debug via Ripple for iOS or Android.
"Unable to attach. Invalid Pointer"
There is no useful output provided by Visual Studio 2013, rather the debugger just doesn't attach to the browser Ripple emulator after showing the exception. The exception happens immediately and the debugger never attaches. I've had this error occur since installation, so it shouldn't have anything to do with the project itself. I checked my paths and they appear to be correct.
System Properties -> Advanced -> System Variables:
ADT_HOME | C:\Users\Name\AppData\Local\Android\android-sdk
ANT_HOME | C:\apache-ant-1.9.3
JAVA_HOME | C:\Program Files (x86)\Java\jdk1.7.0_55
Global Path Variable (last section):
C:\Program Files\nodejs\;C:\Program Files
(x86)\Git\cmd;C:\Program Files (x86)\Windows Kits\8.1\Windows
Performance
Toolkit\;%JAVA_HOME%\bin;%ADT_HOME%\tools;%ADT_HOME%\platform-tools;%ANT_HOME%\bin;C:\Program
Files (x86)\Microsoft SDKs\TypeScript\1.0\
I've made sure that the latest android SDK was installed via the package manager, as suggested here. I've also done multiple reboots since the installation.
Any suggestions on how to fix this error?
Edit
Here's a screen showing Visual Studio's lack of output. There's some general output written while building, but the output is erased immediately when the exception occurs.
I also noticed that I cannot run my application in the Android emulator, which shows that there may be a general installation problem. When trying to run the Android Emulator in Debug mode, I get the following errors:
Let me answer this question in 2 parts:
Debugger not attaching
Multi Device Hybrid Apps CTP1/1.1 only supports debugging on Android devices and emulators 4.4+. This is probably why your debugger fails to attach.
Android emulator not found
It seems that you have not created an AVD (android virtual device), which is why F5 to the Android emulator fails.
Open command prompt and type
android avd
Now, create an AVD image with your preferred configuration and then try to F5 again.
I had the same issue. Don't know if it helps, but in my case I had to uninstall Resharper (Version 8.2).

Visual Studio Script Debugging - Invalid Process 'Type' for inetinfo.exe

I'm having an issue debugging a Classic ASP application from Visual Studio. When I attach to the inetinfo.exe process, I'm getting the message
The breakpoint will not currently be hit. No symbols have been loaded for this document
I think I've isolated the issue as being an incorrect process type being given to inetinfo.exe.
The following screenshot shows what i see when I select 'Debug -> Attach to Process' in Visual Studio 2010:
The inetinfo.exe process "Type" is reported as
T-SQL, Managed (v2.0.50727), x86
Whereas, I would expect it to be:
T-SQL, Script, x86
I have script debugging turned on in IIS, and the application protection level is low. Incidentally, if I flip the application level to medium or high, I see the same on dllhost.exe.
To reiterate, I am trying to debug a Classic ASP Script application, not a managed ASP.NET application.
Is there any reason why (I assume) IIS is getting itself in a pickle?
As it turns out, I should have read my own article on this (Debugging Classic ASP From Visual Studio 2010):
Floundering around, I ran this:
regsvr32.exe "C:\Program Files\Common Files\Microsoft Shared\VS7Debug\pdm.dll"
After an IIS restart I found that this fixed it.
For anyone else toiling with this issue, there is an excellent section in the following article: How to Debug Script Code Using Visual Studio .NET. The section you are looking for is titled "There is no “Script” option for attaching to the script host"

Message: "Visual Studio Remote Debugging Monitor has stopped working" on x64 debugging

Since this morning I keep getting this same message "Visual Studio Remote Debugging Monitor has stopped working" and no matter how many times I restart VS or Windows, that doesn't help. Unfortunately I must use x64 debugging due to third party components. I had no significant changes on the system. From last time everything worked fine.
I've seen this question
VS2008: Unable to start debugging, Remote Debugging Monitor has been closed
and it helped me to understand what is happening but doesn't help me fix the problem...
I am debugging x64 app in local and remote debugger snaps always at the same point of the app start up. The other application still works fine.
Does anyone have some solution for this?
I had a similar debugger issue where details showed that "Fault Module Name" is SYMSRV.dll. So I've fixed that by ticking off "Microsoft Symbol Servers" (Tools->Options->Debugging->Symbols) and cleaning symbols cache.
Sorry, I'm not good at English. I had the same problem. It only happened on my workstation win7 VS2010+SP1. I found that it happened when the program trying to load the assembly "EnterpriseLibrary.ExceptionHandling.Logging.Configuration.Design.dll". Strangely, this assembly references itself! so when the program execution is passing through the statement Assembly.Load("EnterpriseLibrary.ExceptionHandling.Logging.Configuration.Design") in debug mode, the msvsmon.exe crashes with this error message: "visual studio remote debugging monitor has stopped working".
Go to “Start > Run”. Type the following path and hit Enter
C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\Remote Debugger\x64\msvsmon.exe

No debugger working with SilverLight 4 OOB (Out of Browser) app

When I try to use the VS 2010 (Ultimate) debugger on a SL4 OOB application I get this message:
"No Source Available"
No symbols are loaded for any call stack frame. The source code cannot be displayed.
To investigate further, try one of these options:
Browse to find Source (greyed out)
Show Disassembly (if I click on that it comes up with a screen saying "No disassembly available."
Call stack location: (followed by empty space)
What am I missing in order to get VS 2010 to be able to debug a SL4 4 OOB app?
It turns out that it had finished executing and had "nothing to show." This was rather frustrating for someone "new to Visual Studio / Silverlight". Once I put a breakpoint at the startup routine I could step through and do normal debugging of the app.

Resources