android studio无法解析第三方库提供错误13

时间:2015-11-01 11:17:15

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

每当我尝试在我的项目中导入第三方库时,将它包含在gradle.build文件中,android studio会给我错误13. Follwing就是代码示例:

apply plugin: 'com.android.application'

android {
    compileSdkVersion 23
    buildToolsVersion "23.0.2"

    defaultConfig {
        applicationId "com.example.vipul.myapplication"
        minSdkVersion 15
        targetSdkVersion 23
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:appcompat-v7:23.1.0'
    compile 'com.android.support:design:23.1.0'
    compile 'com.jakewharton:butterknife:7.0.1'
}

以下是错误:

Error:(25, 13) Failed to resolve: com.jakewharton:butterknife:7.0.1
<a href="openFile:C:/Users/vipul/Desktop/experimentalandroidprojects/MyApplication6/app/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>

1 个答案:

答案 0 :(得分:0)

从您的本地驱动器中找到“aapt”文件。Click properties -> permissions and check 'Allow executing file as program'。