我在android studio中遇到了这两个错误。如何解决此错误。
Error:(27, 13) Failed to resolve: com.android.support:design:27.+
<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile:D:/android project/My` `Projects/MyApplication2/app/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
和
Error:(26, 13) Failed to resolve: com.android.support:appcompat-v7:27.+
<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile:D:/android project/My Projects/MyApplication2/app/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
这是我的依赖代码
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:27.+'
compile 'com.android.support:design:27.+'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
}
如何解决此错误
答案 0 :(得分:0)