Java 未能解析:com.android.support:design-v7:25.3.1
这是我的学校项目。我的代码有1个错误 未能解析:com.android.support:design-v7:25.3.1 我做过这些事情: A.将我的项目结构配置为25。 B在my dependencies gradle上添加了compile'com.android.support:support-core-utils:25.3.1'。 C.用此代码更新我的另一个gradle D在我的SDK管理器上下载Android API 25Java 未能解析:com.android.support:design-v7:25.3.1,java,android,android-gradle-plugin,Java,Android,Android Gradle Plugin,这是我的学校项目。我的代码有1个错误 未能解析:com.android.support:design-v7:25.3.1 我做过这些事情: A.将我的项目结构配置为25。 B在my dependencies gradle上添加了compile'com.android.support:support-core-utils:25.3.1'。 C.用此代码更新我的另一个gradle D在我的SDK管理器上下载Android API 25 allprojects { repositories {
allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}
而且,我仍然收到那个错误信息
这是build.gridle的完整代码:
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.2"
defaultConfig {
applicationId "com.example.lenovo.home"
minSdkVersion 15
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
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:25.3.1'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.android.support:design-v7:25.3.1'
compile 'com.android.support:support-core-utils:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
}
这是我的错误消息:使用:
compile 'com.android.support:design:25.3.1'
而不是
compile 'com.android.support:design-v7:25.3.1'
作为
这可能会有帮助…-->@JayDangarI已经做了所有这些事情(正如我之前在我的问题中所说的),但是sill收到了相同的错误消息:“)你能在你的问题中添加所有的错误吗?在构建之后,它最终会出现19个错误:”)我在我的应用程序中使用了v7:)Gradle问题必须在这之后解决。v7仅适用于或应用于。。。不是为了设计。
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.2"
defaultConfig {
applicationId "com.example.lenovo.home"
minSdkVersion 15
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
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:25.3.1'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.android.support:design:25.3.1'
compile 'com.android.support:support-core-utils:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
}