You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Android Studio无法选择设备调试进程,OK按钮禁用问题求助

Troubleshooting Grayed-Out OK Button When Debugging Android App

Hey there, fellow Android newbie! I’ve been stuck with this exact issue early on, so let’s walk through the most likely fixes to get your debugger working.

  • ADB isn’t recognizing your device
    Even if you’ve installed drivers, ADB might not be detecting your phone. Open a terminal/command prompt and run:
    adb devices
    If no device shows up:

    • Restart the ADB server: adb kill-server followed by adb start-server
    • Unplug and reinsert your USB cable, or try a different USB port (avoid USB hubs if possible)
    • Check your phone’s USB connection mode—switch to File Transfer (MTP) or Android Auto (some devices block ADB in charging-only mode)
  • Your app isn’t set to debuggable
    Double-check that your build variant is set to Debug (not Release) in Android Studio—release builds disable debugging by default. If you’re working on an older project, make sure your AndroidManifest.xml has the debuggable flag enabled:

    <application
        android:debuggable="true"
        <!-- other attributes -->
    >
    

    (Note: For newer projects using Gradle, this flag is automatically set for debug builds, so you don’t need to add it manually.)

  • You skipped USB debugging authorization
    When you first connect your phone to your computer, a pop-up should appear asking to allow USB debugging from your PC. If you missed this or accidentally denied it:

    • Go to your phone’s Developer Options > Revoke USB debugging authorizations
    • Unplug and reinsert your cable, then tap "Allow" when the pop-up reappears
  • ADB version mismatch between computer and device
    Outdated or mismatched ADB versions can break communication. Update your Android SDK Platform Tools to the latest version via Android Studio’s SDK Manager. After updating, restart the ADB server as mentioned earlier.

  • The app process isn’t properly loaded
    Instead of manually selecting the process, try stopping the app completely, then click the Debug button in Android Studio directly. This will reinstall the debug build and launch the app, which usually makes the process appear automatically with the OK button enabled.


内容的提问来源于stack exchange,提问作者Damara Jati P

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.19 07:39:27