Android Studio错误消息“无法解析依赖项”

时间:2017-12-02 15:00:38

标签: android android-studio-3.0

编辑器中出现的错误是什么意思?我很乐意看到一个完全解释的答案。

Error:Unable to resolve dependency for ':app@debug/compileClasspath': Could not resolve com.android.support:appcompat-v7:26.1.0.
<a href="openFile:C:/Users/MAHE/AndroidStudioProjects/Dork_1/app/build.gradle">Open File</a><br><a href="Unable to resolve dependency for &#39;:app@debug/compileClasspath&#39;: Could not resolve com.android.support:appcompat-v7:26.1.0.">Show Details</a>

enter image description here enter image description here

我正在使用 Android Studio 3.0

Error Code---
Error:FAILURE: Build failed with an exception.

* What went wrong:
Task '~offline' not found in root project 'Dork_1'.

* Try:
Run gradle tasks to get a list of available tasks. Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 2s

1 个答案:

答案 0 :(得分:0)

通常是因为互联网连接问题。确保你有 良好的联系。 有时它会因某些国家的谷歌限制而发生。如果您居住在这些国家/地区,则必须手动添加此库。