Gradle build: resource android:style/TextAppearance.Material not found

我的未来我决定 提交于 2019-11-29 08:00:31

Your compile SDK version MUST match the support library. so here is an example with latest version. Do something similar with yours or update to the latest version (recommended) like below:

1.In your Build.gradle change:

implementation 'com.android.support:appcompat-v7:28.0.0'

2.Change compileSdkVersion and buildToolsVersion to:

compileSdkVersion 28
buildToolsVersion "28.0.3"

3.Update Project gradle file:

classpath 'com.android.tools.build:gradle:3.4.1'

And i suggest you to update all your dependencies in your project in the latest version, i would help you more if you provide us gradle files. Hope this help you.

Take a look at this, could be an issue of support libraries not getting imported

You can also try and clean the project in android studio. Sometimes that helps.

Build -> Rebuild Project

Make sure you have this in your dependencies:

  • if you're using androidx

implementation 'com.google.android.material:material:1.0.0'

  • else

implementation 'com.android.support:design:28.0.0'

Also, check your application's gradle file if it includes google() under repositories section:

allprojects {
    repositories {
      google()
      jcenter()
    }
  }

See https://material.io/develop/android/docs/getting-started/ for more details.

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