Error:Could not find com.android.support:appcompat-v7:27.0.2.

简介: Error:Could not find com.android.support:appcompat-v7:27.0.2.

这是你拉新的项目报错,由于原来的开发者用的Android studio的版本不一样,你的应该是新的版本。

解决:就我的studio版本3.0.1以及gradle.propertory 中4.1

修改位置:项目的build.gradle   :

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

gradle-wrapper.properties中:

distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip

还有就是:

//facebook SDK
compile 'com.facebook.android:facebook-android-sdk:4.28.0'
// firebase 核心库
compile 'com.google.firebase:firebase-core:11.0.4'
compile 'com.google.firebase:firebase-messaging:11.0.4'  

这些版本要对应


还有一点要说的是

dependencies {
    classpath 'io.fabric.tools:gradle:1.+'

在这里面尽量减少用加号表示,尽量明确版本。有些不知名的错误起因就是这个。

目录
相关文章
|
2月前
|
开发工具 Android开发 git
解决Android AAPT: error: resource android:attr/lStar not found. 问题
解决Android AAPT: error: resource android:attr/lStar not found. 问题
118 0
|
2月前
|
Android开发
【Bug】Android resource linking failed和error: failed linking references.
【Bug】Android resource linking failed和error: failed linking references.
|
2月前
|
开发工具 Android开发 Windows
Android应用] 问题2:ERROR: unknown virtual device name:
Android应用] 问题2:ERROR: unknown virtual device name:
17 2
|
2月前
|
Android开发 开发者
安卓投屏神器 Scrcpy安 报错ERROR: Could not find any ADB device
安卓投屏神器 Scrcpy安 报错ERROR: Could not find any ADB device
291 9
|
2月前
|
Android开发 开发者
安卓投屏神器 Scrcpy安 报错ERROR: Could not find any ADB device
使用Scrcpy安卓投屏工具时遇到报错,问题根源是未开启开发者模式。解决步骤:进入设置,点击【关于手机】→连续点击版本号激活开发者模式,然后在【系统设置】→【开发者选项】中开启USB调试。参照此方法后可正常执行。Scrcpy软件下载链接和GitHub页面也已提供。
120 1
|
2月前
解决Error:All flavors must now belong to a named flavor dimension. Learn more at https://d.android.com
解决Error:All flavors must now belong to a named flavor dimension. Learn more at https://d.android.com
35 5
|
2月前
|
XML Android开发 数据格式
Caused by: android.view.InflateException: Binary XML file line #11: Error inflating class
Caused by: android.view.InflateException: Binary XML file line #11: Error inflating class
31 0
|
2月前
|
API Android开发
List.size() 问题 Android studio: Verbose,Debug,Info,Warn,Error
List.size() 问题 Android studio: Verbose,Debug,Info,Warn,Error
22 0
|
11月前
|
XML Android开发 数据格式
Android Binary XML file line #50: Error inflating class androidx.cardview.widget.CardView 错误
Android Binary XML file line #50: Error inflating class androidx.cardview.widget.CardView 错误
64 0
Unable to determine application id: com.android.tools.idea.run.ApkProvisionException: ERROR: APK pat
Unable to determine application id: com.android.tools.idea.run.ApkProvisionException: ERROR: APK pat
309 0