微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

无法解析’:app @ debug / compileClasspath’的依赖关系:无法解析com.android.support:appcompat-v7:26.1.0

无法解析’:app @ debug / compileClasspath’的依赖关系:无法解析com.android.support:appcompat-v7:26.1.0.

无法解析com.android.support:appcompat-v7:26.1.0.

要求:项目:app

No cached version of com.android.support:appcompat-v7:26.1.0 available for offline mode.

错误日志:

Could not resolve all files for configuration ‘:app:debugCompileClasspath’.
Could not resolve com.android.support:appcompat-v7:26.1.0.
required by:
project :app
No cached version of com.android.support:appcompat-v7:26.1.0 available for offline mode.
No cached version of com.android.support:appcompat-v7:26.1.0 available for offline mode.
Could not resolve com.android.support.constraint:constraint-layout:1.1.0-beta3.
required by:
project :app
No cached version of com.android.support.constraint:constraint-layout:1.1.0-beta3 available for offline mode.
No cached version of com.android.support.constraint:constraint-layout:1.1.0-beta3 available for offline mode.
Could not resolve com.android.support:design:26.1.0.
required by:
project :app
No cached version of com.android.support:design:26.1.0 available for offline mode.
No cached version of com.android.support:design:26.1.0 available for offline mode.
Could not resolve com.android.support:cardview-v7:26.1.0.
required by:
project :app
No cached version of com.android.support:cardview-v7:26.1.0 available for offline mode.
No cached version of com.android.support:cardview-v7:26.1.0 available for offline mode.
Could not resolve com.google.android.gms:play-services-ads:11.4.2.
required by:
project :app
No cached version of com.google.android.gms:play-services-ads:11.4.2 available for offline mode.
No cached version of com.google.android.gms:play-services-ads:11.4.2 available for offline mode.
Could not resolve com.android.support:support-v4:26.1.0.
required by:
project :app
No cached version of com.android.support:support-v4:26.1.0 available for offline mode.
No cached version of com.android.support:support-v4:26.1.0 available for offline mode.

错误日志图片

解决方法:

转到文件 – >其他设置 – >认设置 – >构建,执行,部署 – >构建工具 – > Gradle->取消选中离线工作选项.

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐