错误: 模块“应用程序”: 平台“ android-28”未找到。设计编辑器不可用,直到项目同步成功

所以,我是新来的,刚刚安装了 Android Studio,然后想创建一个基本的活动。但问题是,他们想让我安装 SDK 和 Haxm,这不是通过 SDK 管理器安装的。我已经尝试了很多,并且使用了 Stack-overflow 中提到的所有方法来解决这个问题,但是没有一种方法是有效的。

enter image description here

96159 次浏览

I face the same problem. First, install API Level 28 & Restart the Android studio.

First of all! you need to update your sdk manager that too essential tools are: build tools platform tools tools and android Emulator

.....

Now go to LOGCAT , click on configure sdk..... put it to latest and click autoconfig button for each bar.

thats it rebuild it! You are done with 100 percent% successful error solving, Your Activity.xml file will be displayed with out any warning or error!

Go to Tools->sdk manager->install API Level 28 then restart.

I faced the same problem but I uninstalled android studio and reinstalled it while connected to the internet . it downloaded the updated SDK and other tools by its self . it works perfectly

After reinstalling and upgrading my android studio to android 4, I faced the same challnge. but what I did was to go to tool->sdk manager and then install some other APIs including the error messages API 28 not installed and it works fine.

Turn on Internet and open android studio in that select "Tools->sdk manager" and select api level 29, download and apply it. Close android studio and open again 💯✨

  1. go to Tools
  2. Select SDK Manager
  3. Under SDK Platforms select Android 9.0 (Pie) (API 28)
  4. Then Apply and Download the API

Check the buildToolsVersion of your project in app level Gradle file. Then check whether you have installed that sdk version. You can check it on AVD manager. If you haven't buildToolsVersion sdk installed then install first and rebuild the project.

Ex. If your buildToolsVersion is 28 , you should install Android 9.0(Pie) - API Level 28 SDK.

  1. Open Android Studio in order to see 'Welcome screen' (if a project will directly open, you can close it in order to go to the 'Welcome screen')

  2. There is a 'Configure' menu in SDK manager (first option from drop down list).

  3. Open then select the needed android SDK version(s), press ok and wait for downloads (it will take some time until everything is installed).

  4. After this, when you open a project, the 'tools' menu is updated with all missing content.

If you already opened a project, the "SDK Manager" can be found on the main screen SDK Manager Icon

Then you can add the missing sdk.