Visual Studio 2015开发Android App启动调试始终无法完成应用部署的解决方案

创建一个Android App项目后,直接启动调试发现Visual Studio Emulator for Android已成功运行,但应用始终处于Build中(等待时间超过1小时),并未如预期通过adb部署到模拟器中。将应用直接导出apk,拖拽至模拟器直接部署,提示:

File transfer failed. Error: Unable to install the file through Adb. Adb.exe not found. Make sure you have Android SDK Tools installed.

查看进程列表发现adb.exe已经启动,并且和Visual Studio有通信,但XDE和adb.exe没有通信。应该是XDE无法定位Android SDK路径所致。于是运行Process Monitor,再次尝试拖拽apk,终于发现XDE查找名为"HKCUSoftwareMicrosoftVisualStudioEmulatorAndroidAdbPath"的注册表键值,添加对应的键值问题解决。怀疑和我并没有通过Visual Studio直接安装Android SDK有关系,导致一些设置无法生效。

原文地址:https://www.cnblogs.com/junchu25/p/4885814.html