gpt4 book ai didi

android - 找不到与给定名称匹配的资源(在 'dialogCornerRadius' 处,值为 '?android:attr/dialogCornerRadius' )

转载 作者:IT老高 更新时间:2023-10-28 22:12:13 24 4
gpt4 key购买 nike

谁能帮助我为什么在以下内容中出现错误?

Error:(7, 41) No resource found that matches the given name (at 'dialogCornerRadius' with value '?android:attr/dialogCornerRadius').

apply plugin: 'com.android.application'

//Add these lines
def Base_URL = '"' + WEBServiceBaseURL + '"' ?: '"Define BASE URL"';
def SMS_Base_URL = '"' + WEBServiceBaseSMSURL + '"' ?: '"Define SMS BASE URL"';

android.buildTypes.each { type ->
type.buildConfigField 'String', 'Base_URL', WEBServiceBaseURL
type.buildConfigField 'String', 'SMS_Base_URL', WEBServiceBaseSMSURL
}

android {
compileSdkVersion 26
buildToolsVersion "26.0.1"
defaultConfig {
applicationId "com.bla.bla"
minSdkVersion 19
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'

}
}
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:26.+'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
compile 'com.android.support:design:+'
compile files('libs/jxl-2.6.jar')
compile 'com.google.gms:google-services:+'

compile 'com.google.firebase:firebase-core:11.8.0'
compile 'com.google.firebase:firebase-messaging:11.8.0'
}

apply plugin: 'com.google.gms.google-services'

最佳答案

我通过选择

解决了这个问题

API 27+: Android API 27, P preview (Preview)

在项目结构设置中。下图显示了我的设置。构建应用程序时出现的 13 个错误已经消失。

My Gradle settings

关于android - 找不到与给定名称匹配的资源(在 'dialogCornerRadius' 处,值为 '?android:attr/dialogCornerRadius' ),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49171300/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com