Android Studio:“初始化ADB时出错:未找到Android调试桥" [英] Android Studio: "Error initializing ADB: Android Debug Bridge not found"

查看:1335
本文介绍了Android Studio:“初始化ADB时出错:未找到Android调试桥"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经安装了Android Studio 3.0,并且已成功编译和运行应用程序.

I've installed Android Studio 3.0, and have compiled and run applications successfully.

设备文件资源管理器窗格中的上述错误消息以红色显示,并且没有其他内容.

Device File explorer pane has the above error message in red, and nothing else.

推荐答案

每个Android Studio项目都需要有关使用哪种SDK及其位置的信息.在工具"菜单下的"SDK管理器"中定义的整体配置还不够,它似乎是用来下载和安装必要的SDK的,因此

Each Android Studio project requires information as to what SDK is to be used, and where it is located. The overall configuration defined in the SDK Manager under the tools menu is not enough, and it is used seemly to download and install the necessary SDK, so

  • 确保已安装Android SDK.
  • 现在打开或创建一个项目(例如,打开一个APK文件)
  • 然后按照以下步骤为项目定义SDK:
  • make sure you have Android SDK installed.
  • Now opened or create a project (open an APK file for instance),
  • then follow these steps to define the SDK for the project:
  1. 文件->项目结构下,在平台设置下选择 SDK .
  2. 如果在右下窗格中没有 Android SDK 项,请单击绿色的+来添加一个.为它命名为 Android SDK
  3. 并编辑c:\users\yourusername\appdata\local\android\sdk的路径(或SDK Manager中定义的实际位置).
  4. 接下来,仍然在 Project Settings (项目设置)下,选择 Project (项目),然后
  5. 在右下一个窗格中的"Project SDK"下,选择刚创建的新项目SDK.
  6. 保存.
  1. Under File -> Project Structure, select SDKs under Platform Settings.
  2. If you don't have an Android SDK item in the right next pane, then click on the green + to add one. Give it a name of Android SDK,
  3. and edit the path to c:\users\yourusername\appdata\local\android\sdk (or the actual location as defined under SDK Manager).
  4. Next, still under Project Settings, select Project, and
  5. in the right next pane under "Project SDK" select the new project SDK that you just created.
  6. Save.

您的项目已配置.现在打开任务管理器,并杀死所有现有的adb.exe进程. Android Studio现在可以与ADB一起使用了.

Your project is configured. Now open task manager and kill any existing adb.exe processes. Android Studio is now ready to work with ADB.

通过打开设备文件资源管理器(这是AS右下角的垂直选项卡)进行测试,或通过选择附加调试器来进行测试> Android处理按钮,您应该会看到您的Android设备.

Test by opening the Device File Explorer (this is a vertical tab on the very right bottom edge of AS), or test by selecting the Attach debugger to Android Process button, and you should see your Android Device.

如果ADB无法与您的Android设备通信,请检查是否已安装 Android USB驱动程序.另外,电话必须处于开发人员模式,ADB才能使用它.

If ADB doesn't communicate with your Android device, check to see if you have installed the Android USB driver. Also, the phone needs to be in developer mode for ADB to work with it.

最后一点,当我使用 Administrator 特权启动AS时,我在AS/ADB上取得了更大的成功.我希望这些信息对某人有所帮助.

Last point, I have had more success with AS/ADB when I launch AS with Administrator privileges. I hope this information is helpful to someone.

这篇关于Android Studio:“初始化ADB时出错:未找到Android调试桥"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆