当我导入eclipse项目到AS时,出现错误:
E:\studioWorkspace\YTHDBL\yTHDBL\build.gradle
Error:Error:line (25)Failed to resolve: com.android.support:appcompat-v7:22.2.1
Install Repository and sync project
Show in File
open.dependency.in.project.structure
Show in Project Structure dialog</a>
Error:Error:line (24)Failed to resolve: com.android.support:support-v4:22.2.1
Install Repository and sync project
Show in File
open.dependency.in.project.structure
Show in Project Structure dialog
我搜索答案并找到了这个:how do I properly install support_v7
我是否设置了错误的支持库编号?,我尝试了22.0.0,22.2.0.....,但不起作用。
在我的 sdk 管理器中,已安装 Android 支持存储库,版本 16,并且已经安装 Android 支持库,版本 22.2.1。 谷歌存储库也已安装。
这是我的 build.gradle:
dependencies {
compile project(':library')
compile project(':alipay_lib')
compile project(':sMSSDK')
compile 'com.android.support:support-v4:22.2.1'
compile 'com.android.support:appcompat-v7:22.2.1'
compile files('libs/alipay.jar')
compile files('libs/android-query.0.25.10.jar')
compile files('libs/baidumapapi_v3_1_0.jar')
compile files('libs/commons-codec-1.6.jar')
compile files('libs/jackson-core-asl-1.9.11.jar')
compile files('libs/jackson-mapper-asl-1.9.11.jar')
compile files('libs/jpush-sdk-release1.7.5.jar')
compile files('libs/locSDK_4.2.jar')
compile files('libs/umeng-analytics-v5.5.3.jar')
compile files('libs/zxing.jar')
}
问题出在哪里?现在我在AS中找不到“重试”按钮,我该如何重试?
最佳答案
我打开了 android_sdk,然后更新了 Android 支持存储库、Android 支持库和 Google 存储库,因此 Intellij 中的问题得到了解决。
关于android - 无法解析 : com. android.support :appcompat-v7:22. 2.1,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31740393/