1
加入這行來我的build.gradle未能同步級項目
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.2.2'
// in the individual module build.gradle files
compile "com.android.support:support-core-utils:25.0.1"
}
}
allprojects {
repositories {
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
然後我跟着鏈接,打開的Android SDK管理器,我發現我已經安裝了Android的詢問服務存儲庫
的原因,我加入這個文件到我的等級是因爲它已被張貼在那裏
Cannot resolve symbol 'TabsPagerAdapter'
根據錯誤信息,將'compile'行放在'build.gradle'文件的錯誤位置。你可能會考慮編輯你的問題併發布完整的'build.gradle'文件。 – CommonsWare
好的,我提出了你的建議。你想把你的編譯行放在哪裏? –
Matias的答案涵蓋了這一點。 FWIW,我提交了[錯誤報告](https://code.google.com/p/android/issues/detail?id=228489)關於安裝Android支持資源庫的錯誤建議。另外,關於'TabsPagerAdapter',Android SDK中沒有這樣的類,我可以找到它,這似乎是一個單獨的問題。 – CommonsWare