Forum Visual Studio

Unable to deploy to VS Android Emulator for Android projects, but can do for Cross Platform Projects

ravl13ravl13 USMember ✭✭

I have a problem with the Visual Studio Android Emulator, for VS2015. This one:,_testing,_and_metrics/debug-on-emulator/visual-studio-android-emulator/

When I test projects on a physical Android device, I encounter no issues. I'm using the green triangular "Play" looking button, towards the top middle of Visual Studio.

Also, when I try deploying a project to an emulator, if it's a cross platform solution, the kind that has both an android and an iOS project in it, I can deploy to the emulator fine.

However, if I try deploying a straight Android project/solution to an emulator (no iOS component at all), the emulator launches, but no project is deployed - the emulator just sits there doing nothing - I can "use" the emulator to use existing apps already on the emulator, but there's no trace of my app. There's no errors displayed - and after a couple minutes, Visual Studio just displays the blue "Ready" status at the bottom of Visual Studio 2015, even though my project hasn't succeeded or failed at deployment.

Below are the two Android 6.0 Visual Studio emulators I have tested on, both of them having the same failure:

This is not some kind of bug with a prior version of the app somehow being on the emulator beforehand. To guarantee this, I changed the package name, and still got the same failure. And checking the running emulator after the deploy fails, reveals no trace of the package name in the Settings > Apps list

Linking is off. Use Shared Runtime is off. Preserve application data cache on device between deploys is off (this is in the Xamarin > Android Settings screen).

I have the most recent version of Xamarin installed as of 8/21.

Here is the output from VS2015 when I try to use the emulator for the solo Android project - there's no errors or warnings:

_1>Starting deploy 10.1" Marshmallow (6.0.0) XHDPI Tablet ...
1>Starting emulator 10.1" Marshmallow (6.0.0) XHDPI Tablet ...
1>Validating emulator arguments...
1>Determining if emulator is already running...
1>Preparing virtual machine...
1>Launching emulator...
1>Emulator launched successfully.
1>Emulator 10.1" Marshmallow (6.0.0) XHDPI Tablet is running.
1>Waiting for emulator to be ready...
1>Deploying 10.1" Marshmallow (6.0.0) XHDPI Tablet ...
1>Build started.
1>Project "HiLo.csproj" (Install target(s)):
1>C:\Program Files (x86)\MSBuild\14.0\bin\csc.exe /noconfig /nowarn:1701,1702,2008 /nostdlib+ /errorreport:prompt /warn:4 /define:DEBUG;TRACE;__XAMARIN_ .....
**(Outputs a large amount of directories - not important, so I'll skip it)_**
1>HiLo -> C:\v\MYAPPXamarin v1.1\MYAPPXamarin\Mod10\Solutions\Ex07\HiLo\HiLo\bin\Debug\HiLo.dll
1> Processing: obj\Debug\res\layout\main.xml
1> Processing: obj\Debug\res\layout\stats.xml
1> Processing: obj\Debug\res\values\strings.xml
1>C:\Program Files\Java\jdk1.8.0_144\bin\keytool.exe -list -alias androiddebugkey -storepass android -keypass android -keystore "C:\Users\Administrator\AppData\Local\Xamarin\Mono for Android\debug.keystore"
1>C:\Program Files\Java\jdk1.8.0_144\bin\jarsigner.exe -keystore "C:\Users\Administrator\AppData\Local\Xamarin\Mono for Android\debug.keystore" -storepass android -keypass android -digestalg SHA1 -sigalg md5withRSA -signedjar bin\Debug\HiLo.HiLo-Signed-Unaligned.apk "C:\v\MYAPPXamarin v1.1\MYAPPXamarin\Mod10\Solutions\Ex07\HiLo\HiLo\obj\Debug\android\bin\HiLo.HiLo.apk" androiddebugkey
1>No -tsa or -tsacert is provided and this jar is not timestamped. Without a timestamp, users may not be able to validate this jar after the signer certificate's expiration date (2047-08-10) or after any future revocation date.
1>C:\Users\Administrator\AppData\Local\Android\sdk\build-tools\23.0.0\zipalign.exe 4 "C:\v\MYAPPXamarin v1.1\MYAPPXamarin\Mod10\Solutions\Ex07\HiLo\HiLo\bin\Debug\HiLo.HiLo-Signed-Unaligned.apk" "bin\Debug\HiLo.HiLo-Signed.apk"

Any ideas on why my Visual Studio emulator doesn't work for Android-only solutions?


  • kentuckerkentucker USMember ✭✭✭✭✭

    Open hyper-v manager and find the emulator. Shut it down if is running and make sure compatibility is checked under processor. Run it again

Sign In or Register to comment.