I'm using VS 2015 RC, and I'm writing a cross platform mobile application. I have all the normal tools (java, android sdk, xamarin, cordova, etc.) installed and working. All the development is going well. I can debug just fine. Windows Phone 8.1 emulator run and debugs great. iOS simulator runs and debugs great.
When I try to run the MS Android Emulator (debug from VS), my project builds successfully (.apk gets created), and the Android emulator launches and starts the emulator OS just fine.
However, after the MS Android emulator starts, I get a pop up saying "Could not locate Android Debug Bridge (adb.exe)". My application never shows up on the emulator screen, and VS tells me deployment failed.
adb.exe is installed and working just fine (D:\Program Files (x86)\Android\android-sdk\platform-tools\adb.exe). I can go to command prompt, and execute it from anywhere (it's in my system PATH). ADB will work generically thru command prompt, detect devices, and everything just fine normally. It's only thru VS does it error out.
Where could VS be looking for adb.exe at? Could it be related to me choosing to install the Android SDK (including tools like adb.exe) on my D: drive (not my C:)?
The primary way to resolve these problems manually is to replace the EXE file with a fresh copy. Additionally, some adb.exe errors can be due to incorrect registry references, so we recommend conducting a registry scan to clean up any invalid entries.
As it turns out, if you are missing the relevant Android version SDK on your system, that will also cause the error message to arise. If this case is applicable, you can easily resolve the error message by installing the respective Android SDK from the SDK Manager found in the Android Studio.
Update ADB Interface Open Device Manager. Right-click on the option Android ADB Interface or Android Phone, located under Other Devices and -> Select Update Driver Software. Select Browse my computer for driver software -> Select Let me pick from a list of device drivers on my computer.
A similar error exists in VS2019. To fix that:
1) Visit Android's Dev Studio site
2) Scroll past all the Studio stuff, that's gigs of stuff you don't need - click Download Options and skip to the "Command Line Tools only" - download that
3) Wherever you unzip its contents, navigate to the tools\bin folder inside and open a Command Prompt there.
4) Run sdkmanager platform-tools
5) Give it a minute.
You've now got adb.exe on your machine. It's going to be sitting inside a folder like C:\Program Files (x86)\Android\android-sdk\platform-tools\adb.exe
. Wherever it is, go open your Xamarin app and double-click the error complaining it can't find adb.exe. One last curve ball: In the above path, Visual Studio wants you to pick the folder named android-sdk
. That is, not the platform-tools
folder, which contains adb.exe, but, the folder above that, that contains the platform-tools
folder.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With