Mom*_*afa 16 android dart flutter
我使用 Android Studio 作为我编写 Flutter 的 IDE。在此之前,我能够创建 2 个项目,并且效果非常好。我不得不从 Github 克隆一个 repo。IDE 说要获取配置。我这样做了然后这发生了。

我已经安装了 sdk 。
颤振医生结果:
[?] Flutter (Channel stable, v1.12.13+hotfix.8, on Microsoft Windows [Version 10.0.18363.720], locale en-US)
• Flutter version 1.12.13+hotfix.8 at C:\src\flutter\flutter
• Framework revision 0b8abb4724 (6 weeks ago), 2020-02-11 11:44:36 -0800
• Engine revision e1e6ced81d
• Dart version 2.7.0
[X] Android toolchain - develop for Android devices
X Unable to locate Android SDK.
Install Android Studio from: https://developer.android.com/studio/index.html
On first launch it will assist you in installing the Android SDK components.
(or visit https://flutter.dev/setup/#android-setup for detailed instructions).
If the Android SDK has been installed to a custom location, set ANDROID_HOME to that location.
You may also want to add it to your PATH environment variable.
[?] Android Studio (version 3.6)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin version 44.0.2
• Dart plugin version 192.7761
• Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b04)
[!] Android Studio
• Android Studio at C:\Program
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
X android-studio-dir = C:\Program
X Android Studio not found at C:\Program
• Try updating or re-installing Android Studio.
• Consider removing your android-studio-dir setting by running:
flutter config --android-studio-dir=
[!] VS Code
• VS Code at C:\Users\Tamim Mostafa\AppData\Local\Programs\Microsoft VS Code
X Flutter extension not installed; install from
https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter
[!] Connected device
! No devices available
! Doctor found issues in 4 categories.
Run Code Online (Sandbox Code Playgroud)
我还尝试将目录更改为没有空格的 using 文件夹。我将 Sdk 文件夹移动到 D:\Android\Sdk。扑医生-v:
[?] Flutter (Channel stable, v1.12.13+hotfix.8, on Microsoft Windows [Version 10.0.18363.720], locale en-US)
• Flutter version 1.12.13+hotfix.8 at C:\src\flutter\flutter
• Framework revision 0b8abb4724 (6 weeks ago), 2020-02-11 11:44:36 -0800
• Engine revision e1e6ced81d
• Dart version 2.7.0
[X] Android toolchain - develop for Android devices
X ANDROID_HOME = D:\Android\Sdk
but Android SDK not found at this location.
[?] Android Studio (version 3.6)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin version 44.0.2
• Dart plugin version 192.7761
• Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b04)
[!] Android Studio
• Android Studio at C:\Program
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
X android-studio-dir = C:\Program
X Android Studio not found at C:\Program
• Try updating or re-installing Android Studio.
• Consider removing your android-studio-dir setting by running:
flutter config --android-studio-dir=
[!] VS Code
• VS Code at C:\Users\Tamim Mostafa\AppData\Local\Programs\Microsoft VS Code
X Flutter extension not installed; install from
https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter
[!] Connected device
! No devices available
! Doctor found issues in 4 categories.
Run Code Online (Sandbox Code Playgroud)
小智 25
它解决了我的问题:

Mak*_*aki 14
我遇到了同样的问题,对我有用的是重新导入项目。
File > Close Project,转到项目目录并删除.idea文件夹。然后File > Open...重新打开项目。
打开Project Structure,您可以使用您拥有的设置项目的 SDK。

找了半天才发现Project其他人都看到了,估计是Android Studio版本更新了。我External Libraries在左侧面板和它下面找到了它,右键单击Android API (NN) Platform> Open Library Settings>Project下面Project Settings和右侧面板,更改 Android API。我有<No SDK>,看截图。
这似乎是问题所在:
[X] Android toolchain - develop for Android devices
-> ANDROID_HOME = D:\Android\Sdk but Android SDK not found at this location.
Run Code Online (Sandbox Code Playgroud)
由于您说将 Android SDK 添加到 D 目录,因此您可以将D:\Android\sdk\tools和添加D:\Android\sdk\platform-tools到 PATH 环境变量中。这是将其添加到 Path 环境变量的方法:https : //docs.telerik.com/teststudio/features/test-runners/add-path-environment-variables
那是警告说“ Android SDK 位置不应包含空格”。中有一个空白字符Tamim Mustofa。
您可以将 sdk 文件夹移动到新文件夹D:\Android\Sdk,例如 ,其中路径中没有空格或其他空白字符。在Android Studio中更改Android Sdk Location地址。并ANDROID_HOME在环境变量:系统变量中添加变量。作为D:\Android\Sdk变量值
| 归档时间: |
|
| 查看次数: |
19636 次 |
| 最近记录: |