Forum Xamarin Xamarin.Android

How can I debug an Android Application?

I have been trying to get the debugger to work on a physical device. The application can Start Without Debugging (but the device shows, 'Waiting for debugger...', it can Upload to Device and it runs fine, but Start Debugging, does it preliminaries, uploading the application, but then simply does nothing. The application is on the device, but Visual Studio for Mac, does not start debugging. Many times when attempting anything, Upload, Start Without Debugging, it never finishes deploying. I am using Visual Studio Community 2019 for Mac and the app is the the Xamarin_Android__MediaBrowserService. I have made no changes to the code! Any help would be most welcome.


  • gingerdudegingerdude USMember ✭✭

    I also updated to the latest and cannot get my Android builds to deploy to the physical device. Exact same issue as you.

  • RobertDalyRobertDaly USMember ✭✭
    I’m glad I’m not the only one, but now that the question shows ‘answered’ should I start a new thread?
  • LandLuLandLu Member, Xamarin Team Xamurai
    edited September 2019

    Have you tried to debug a blank project? Will it occur on iOS?
    Have you tried to debug with emulators?
    Try to delete the bin/obj folders and rebuild again. Moreover, make sure your Mac has enough disk space to run the debugger.
    If the issue persists you could open a one-on-one ticket here:

  • RobertDalyRobertDaly USMember ✭✭

    I did everything you indicated! I created a blank project ('Shows Hello World!). It will deploy without a problem if I Start Without Debugging, and will run, it deploys and runs successfully if I Upload to Device, but if I Start Debugging, it will upload it to the device, but no debugging. The other thing I noticed is that if I enable Use Shared Mono Runtime (which I think is necessary for debugging, all three of the options will fail with an unhandled exception: System.ComponentModel.Win32Exception. I believe this may be the issue, but I don't know how to resolve it!

  • RobertDalyRobertDaly USMember ✭✭

    I forgot to mention that I also tried to use the emulator for this. Unfortunately, in all cases, the System.ComponentModel.Win32Exception appears, regardless of whether or not Use Shared Mono Runtime is set or not.

  • gingerdudegingerdude USMember ✭✭

    I have tried all of these too.

    iOS works fine both simulator and device.

    Android works fine on the emulator, but the device is a no go.

    New project results in the same issue.

Sign In or Register to comment.