找不到元素"资源"的声明



我试图将Adobe Creative Sdk添加到Android应用程序中,我遵循此(https://creativesdk.adobe.com/docs/android/#/articles/gettingstarted/index.html)教程,但是当我同步项目时,错误显示在logcat上…

C:UsersMuzamil HussainAndroidStudioProjectsSwitchAppappbuildintermediatesresmergeddebugvaluesvalues.xml
Error:(2599, 44) No resource found that matches the given name (at 'android:textColorHint' with value '@color/hint_foreground_material_light').
Error:(2599, 44) No resource found that matches the given name (at 'android:textColorHint' with value '@color/hint_foreground_material_light').
Error:Execution failed for task ':app:processDebugResources'.
> com.android.ide.common.process.ProcessException: Failed to execute aapt

for value.xml文件

我的gradle app文件:

apply plugin: 'com.android.application'
/* 1) Apply the Gradle Retrolambda Plugin */
apply plugin: 'me.tatarka.retrolambda'

android {
    compileSdkVersion 24
    buildToolsVersion '24.0.3'
    defaultConfig {
        applicationId "com.example.muzamil_hussain.switchapp"
        minSdkVersion 16
        targetSdkVersion 24
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
        manifestPlaceholders = [appPackageName: "dfc,,,,myapi key........mmmm"]
    }
    packagingOptions {
        exclude 'META-INF/LICENSE'
        exclude 'META-INF/LICENSE-FIREBASE.txt'
        exclude 'META-INF/NOTICE'
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    /* 2) Compile for Java 1.8 or greater */
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
    /* 3) Exclude duplicate licenses */
    packagingOptions {
        exclude 'META-INF/LICENSE.txt'
        exclude 'META-INF/LICENSE'
        exclude 'META-INF/NOTICE.txt'
        exclude 'META-INF/NOTICE'
        exclude 'META-INF/DEPENDENCIES'
        pickFirst 'AndroidManifest.xml'
    }
    // This is handled for you by the 2.0+ Gradle Plugin
    aaptOptions {
        additionalParameters "--no-version-vectors"
    }
}
repositories {
    mavenCentral()
}
dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    compile 'com.android.support:appcompat-v7:24.0.3'
    testCompile 'junit:junit:4.12'
    compile 'com.google.firebase:firebase-database:9.8.0'
    compile 'com.google.firebase:firebase-core:9.8.0'
    compile 'com.google.firebase:firebase-auth:9.8.0'
    compile 'com.google.firebase:firebase-storage:9.8.0'
    compile 'com.google.firebase:firebase-crash:9.8.0'
    compile 'com.google.firebase:firebase-messaging:9.8.0'
    compile 'com.facebook.android:facebook-android-sdk:[4,5]'
    compile 'com.google.android.gms:play-services-appindexing:9.8.0'
    compile 'com.firebase:firebase-client-android:2.5.2'
    compile 'com.firebaseui:firebase-ui:0.6.2'
    compile 'com.squareup.picasso:picasso:2.5.2'
    compile 'com.squareup.okhttp:okhttp:2.4.0'
    compile 'com.pkmmte.view:circularimageview:1.1'
    compile 'com.github.QuadFlask:colorpicker:0.0.12'
    compile 'com.squareup.okhttp:okhttp-urlconnection:2.7.4'
    compile 'com.adobe.creativesdk.foundation:auth:0.9.1186'
    compile 'com.adobe.creativesdk:image:4.6.3'
    compile 'com.localytics.android:library:3.8.0'
}
apply plugin: 'com.google.gms.google-services'

和这个版本。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'
        classpath 'com.google.gms:google-services:3.0.0'
        /* 1) Add the Gradle Retrolambda Plugin */
        classpath 'me.tatarka:gradle-retrolambda:3.3.0-beta4'
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}
allprojects {
    repositories {
        jcenter()
        maven { url "https://jitpack.io" }
        /* 2) Add mavenCentral */
        mavenCentral()
        /* 3) Add the Creative SDK Maven repo URL */
        maven {
            url 'https://repo.adobe.com/nexus/content/repositories/releases/'
        }
        maven {
            url 'http://maven.localytics.com/public'
        }

    }
}
task clean(type: Delete) {
    delete rootProject.buildDir
}

启用android支持。

进入文件>设置>插件,然后启用它。

最新更新