Search code examples
androidcordovavisual-studio-2015visual-studio-debugging

Why Visual Studio 2015 loses debugging attach when try to debug Cordova application


I've just created a blank cordova application in Visual Studio Entreprise 2015. It compiles and deploys correctly to the device, but it does not holds the attach. It loses the attach immediatly as the debug begins. It breaks the attach right before Visual Studio prints a warning message (not error) stating that: "An error ocurred trying to attach to the Google Android Emulator. Exception: invalid pointer".

Everything seems ok. I also tested an Android basic project in the Android Studio. Debugged sucesfully.

I could even debug a basic Cordova project using Visual Studio Code and it worked perfectly.

I don't know what I can try next to solve this problem.

Visual Studio Entreprise is installed in the system drive, as jdk. Apache Ant and Android SDK are in other system drive. Those are the only things that are out of the usual. Also, I've instaled the Xamarin tools on Visual Studio.

I've just formated the computer a few days ago. Using the Windows 10 Pro, and never faced such problem before.

What can be hapenning?


Solution

  • I suggest you run your VS as the admin which sometimes could resolve the loaded issue or the access permission issue.