Android SDK missing with Android Studio 3

倾然丶 夕夏残阳落幕 提交于 2019-11-26 20:35:16

问题


I've just downloaded Android Studio 3 for Windows from the official website, but when it starts, it displays an error message about a missing Android SDK:

When I click that link, it just redirects to the same official website. There isn't a separate link there for SDK download.

Where could I get it from? Shouldn't the Android SDK be installed during Android Studio 3 setup?


回答1:


Apparently, the problem was that Android Studio 3.0 had already been installed and uninstalled before this. The SDK got removed, but Android Studio's config didn't.

Removing the config from a previous install (C:\Users\<user>\.AndroidStudio3.0 folder) did the trick. When Android Studio started up, it opened a dialog about which parts of the SDK to download, and then proceeded as expected.




回答2:


This happened with me on Windows 10 with Android Studio 3.1. The SDK was missing & I couldn't download or install it with the IDE. Android Studio wasn't downloading or installing the SDK properly, despite going through the steps. An error would appear at the end of the SDK configuration wizard telling me the SDK hadn't been installed b/c the sdk/tools directory didn't exist (no sh1t sherlock). I had not previously downloaded or installed Android Studio or the SDK.

It turns out that Android Studio 3.1 didn't have option checked for 'Enable embedded Maven repository' in the IDE Preferences.

After enabling the embedded Maven repo & restarting Android Studio, the SDK configuration wizard started up & successfully downloaded/installed the SDK.




回答3:


I uninstalled Android Studio from Control Pannel. Save in a safe place the folder and subfolders below C:\USERS\MYNAME\ANDROIDSTUDIOPROJECTS

After I deleted c:\users\MYNAME\.ANDROIDSTUDIO3.1 AND c:\users\MYNAME\.ANDROID

After all I installed android studio. Take a long time but it resolved the problem.




回答4:


try to reinstall it and download(automatically downloaded) the required file after restart, but follow the steps

1 go to your main drive(consider 'c') then c/user//androidstudioproject and copy it to some other location(save your old projects to safe location)

2 uninstall android studio from control panel

3 delete following file

    a c/user/<your system name>/androidstudioproject

    b c/user/<your system name>/.android

  c 'c/user/<your system name>/AppData/Local/Android (keep hidden files on)'

4 now install your androidstudio from its setup

these will automatically download the required files after installation (always connect to internet while installing)




回答5:


You can download sdk tools separately.

https://developer.android.com/studio/#downloads
Go to this link and download the sdk tools from under "Command line tools only".

after download, extract the zip file and move it to C:\Users\USERNAME\AppData\Local\Android\Sdk

If not worked, change sdk location from android studio




回答6:


I ran into this and after uninstall and reinstall, still could not find the option under Tools.

After I opened a project, I found the option. There is a button (fourth from the right) that is the SDK Manager.




回答7:


Its simple, go the tab tools in android studio, click on it than click SDK manager. It will open a window called settings for new projects. Go to android SDK than select the SDK u want to download. This will definitely work.




回答8:


I had to manually create
C:\Users\[USERNAME]\AppData\Local\Android\Sdk

and then I downloaded the tools from Command Line Tools Only section on: https://developer.android.com/studio/#downloads

then I extracted the files to:
C:\Users\[USERNAME]\AppData\Local\Android\Sdk

Hope this helps someone.



来源:https://stackoverflow.com/questions/46962775/android-sdk-missing-with-android-studio-3

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!