找不到appcompat-v7.jar(com.android.support:appcompat-v7:24.1.1)

时间:2016-12-09 10:16:35

标签: android android-studio android-gradle build.gradle

我的应用程序一直在使用此build.gradle文件顺利运行。 然后,我需要显示TreeView,因此我必须使用bmelnychuk/AndroidTreeView中的第三方库。

当我将compile 'com.github.bmelnychuk:atv:1.2.+'添加到build.gradle文件中时,会显示以下错误:

  

错误:配置项目':app'时出现问题。   找不到appcompat-v7.jar(com.android.support:appcompat-v7:24.1.1)。     在以下位置搜索:         https://jcenter.bintray.com/com/android/support/appcompat-v7/24.1.1/appcompat-v7-24.1.1.jar

这是gradle文件:

apply plugin: 'com.android.application'

android {
    compileSdkVersion 24
    buildToolsVersion "24.0.1"

    defaultConfig {
        applicationId "com.ada.foresight"
        minSdkVersion 17
        targetSdkVersion 24
        versionCode 1
        versionName "1.0"
        // Enabled multidex support
        multiDexEnabled true
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:appcompat-v7:24.1.1'
    compile 'com.android.support:design:24.1.1'
    compile 'com.android.support:multidex:1.0.0'
    compile 'com.android.support:recyclerview-v7:24.1.1'
    compile 'com.android.support:support-v4:24.1.1'
    compile 'com.android.volley:volley:1.0.0'
    compile 'com.google.code.gson:gson:2.7'
    compile 'com.prolificinteractive:material-calendarview:1.4.0'
    compile 'com.squareup.okhttp3:okhttp:3.4.1'
    compile 'com.squareup.okhttp3:okhttp-urlconnection:3.4.1'
    compile 'com.android.support:percent:22.2.0'
    compile 'com.github.satyan:sugar:1.4'
    // problem occur while I added this line:
    //compile 'com.github.bmelnychuk:atv:1.2.+'       
}

请帮忙。

0 个答案:

没有答案
相关问题