首页 文章

找不到与给定名称匹配的资源:'android:TextAppearance.Material.Widget.Button.Inverse'

提问于
浏览
0

该项目运行良好 . 我试图添加一个片段,我收到了以下错误 .

检索项目的父项时出错:找不到与给定名称“android:TextAppearance.Material.Widget.Button.Inverse”匹配的资源 . 检索项目的父项时出错:找不到与给定名称“android:Widget.Material.Button.Colored”匹配的资源 . 错误:任务':app:processDebugResources'的执行失败 . com.android.ide.common.process.ProcessException:org.gradle.process.internal.ExecException:进程'命令'C:\ Users \ Th \ AndroidSdk \ build-tools \ 21.1.1 \ aapt.exe''已完成非零退出值1

我什么都没改变 .

摇篮:

compileSdkVersion 21
buildToolsVersion "21.1.1"

defaultConfig {
    applicationId "com.example.app.app"
    minSdkVersion 14
    targetSdkVersion 21
    multiDexEnabled = true
}

请指导我 . 谢谢 .

2 回答

  • 0

    enter image description here

    只是如图所示,它将解决问题!

  • 0
    targetSdkVersion 21
    

    这不起作用,因为API 22及更低版本没有像API 23那样的材料设计(您根据错误尝试使用它) . 您必须使用AppCompat v21 . 这个问题也可以帮助您回答您的问题:Implement material design in android 5.0 and lower

相关问题