Android Studio update 0.5.3 - platform 'android-19' not found

家住魔仙堡 提交于 2019-11-30 02:42:47
cholm

I had the same problem.

Deleting ~/.AndroidStudioPreview (on Debian GNU/Linux 'sid') fixed the problem. This directory was from an older version of AS (0.3.x). I don't know what the equivalent of the GNU/Linux ~/.AndroidStudioPreview is on Windows/Mac OS X/... (for Windows it's under C:\Users\<user>\.AndroidStudioPreview\).

Deleting the following fixed my problem -

~/Library/Caches/AndroidStudioPreview

~/Library/Logs/AndroidStudioPreview

~/Library/Preferences/AndroidStudioPreview

Update your Android SDK tools to version 22.6.2, and install android-19. It worked for me!

Go to your Module Settings and set project SDK.

Had this problem too in 0.5.3 and the only way I could fix it was to downgrade to 0.5.2.

Even though I added the SDK manually in the project structure window, it would not import android class files properly.

0.5.2 is available here: http://tools.android.com/download/studio/canary/0-5-2

Delete your .AndroidStudioPreview folder and run Android Studio again. Unfortunately you will lose your settings.

I was able to just open the SDK Manager and install the updates it found. I had installed new things recently, yet it found six new packages to install. My guess is the new version of the SDK tools is what fixed the gradle problem. Works fine now. No downgrade, no hidden file deletions.

Wait, I was installing 0.5.4 not 3.

Just found out that updating the SDK platform 19 to revision 3 solved this problem for me. For instance I'm using Android Studio 0.5.4 as well.

Go to the SDK manager and install Extras -> Android Support Repository

I had the same problem but my reason was because I had two SDK Managers and my Android Studio had the wrong SDK Manager directory.

The first SDK Manager was from my Eclipse-Android SDK that I installed a few years back. The directory it is located in is C:\Program Files (x86)\Android\android-studio\sdk

The 2nd SDK Manager was for my Android Studio. The directory it is located in is C:\Users\Gene\Android SDK\sdk

In Android Studio, go to File -> Project Structure. On the left tabs, choose “SDK Location”. Make sure you’re pointing the project at the right SDK Location.

If you need to access the SDK Manager for Android Studio in order to download more APIs, you might need to right click on “SDK Manager.exe” and then click “Run as administrator” in order for you to get it to work.

Whatever SDK Manager you are using, make sure you downloaded the API for it before you set "compileSdkVersion" (in gradle) to that API version.

I have the same issue just that i cannot change form version 19 to 18. Even though I have both versions installed. I use Android Studio version 0.5.4. One person at the office has the same setup without any problems on the same project. The fix with deleting the folder .AndroidStudioPreview works for one project, but then another I work on breaks.

Had the same problem after clean install of Android Studio 1.1.0 on OSX Yosemite. Deleting folders did not work. What did work was simply run sudo android, from terminal.

Build tools and Android SDK platform are two different things. When Gradle tells you that you miss android-19, it means that you did not get the latest version of the Android SDK (level 19)

You need to install this version.

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