日食';Android设计支持库的错误

日食';Android设计支持库的错误,android,eclipse,Android,Eclipse,我正试图将库“android.support.design”导入eclipse,但导入后出现了一些错误: /design/res/values/styles.xml:21: error: Error: No resource found that matches the given name: attr 'backgroundTint'. /design/res/values/styles.xml:23: error: Error: No resource found that matches

我正试图将库“android.support.design”导入eclipse,但导入后出现了一些错误:

/design/res/values/styles.xml:21: error: Error: No resource found that matches the given name: attr 'backgroundTint'.
/design/res/values/styles.xml:23: error: Error: No resource found that matches the given name: attr 'elevation'.
/design/res/values/styles.xml:34: error: Error: No resource found that matches the given name: attr 'elevation'. 
/design/res/values/styles.xml:56: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Button'.
/design/res/values/styles.xml:59: error: Error: No resource found that matches the given name: attr 'textAllCaps'.
/design/res/values/styles.xml:67: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Caption'.      
/design/res/values/styles.xml:71: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Caption'.     
/design/res/values/styles.xml:80: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Button'.     
/design/res/values/styles.xml:91: error: Error: No resource found that matches the given name: attr 'elevation'. 
/design/res/values/styles.xml:103: error: Error: No resource found that matches the given name: attr 'elevation'.  
/design/res/values/styles.xml:111: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Display1'. 
/design/res/values/styles.xml:21: error: Error: No resource found that matches the given name: attr 'backgroundTint'.
/design/res/values/styles.xml:23: error: Error: No resource found that matches the given name: attr 'elevation'.
/design/res/values/styles.xml:34: error: Error: No resource found that matches the given name: attr 'elevation'.  
/design/res/values/styles.xml:56: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Button'.
/design/res/values/styles.xml:59: error: Error: No resource found that matches the given name: attr 'textAllCaps'.
/design/res/values/styles.xml:67: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Caption'.
/design/res/values/styles.xml:71: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Caption'.
/design/res/values/styles.xml:80: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Button'.
/design/res/values/styles.xml:91: error: Error: No resource found that matches the given name: attr 'elevation'.
/design/res/values/styles.xml:103: error: Error: No resource found that matches the given name: attr 'elevation'.
/design/res/values/styles.xml:111: error: Error retrieving parent for item: No resource found that matches the given name 'TextAppearance.AppCompat.Display1'.
我该怎么修理?
谢谢。

根据本Android开发者博客的Android设计支持库,Support v4和AppCompat支持库是构建设计支持库的依赖项。


因此,在Eclipse中,右键单击android支持设计库项目->属性->android,转到底部的库部分,然后单击添加。。将AppCompat库添加到项目中。

将其添加到build.gradle中

dependencies {

    compile 'com.android.support:appcompat-v7:22.2.0'
    compile 'com.android.support:design:22.2.0'
    compile 'com.android.support:support-v4:22.2.0'
}
在eclipse中:(添加以上所有jar)


你导入资源文件了吗?我还建议你转到Android Studio。再见,Gabriele,Ho provato ad Utilizare Android Studio ma preferisco continuare con Eclipse。根据l'importazione faccio在questo modo:File->Import->将现有Android代码导入工作区->/Android sdk/extras/Android/support/design Come faccio con ad esempio google-play-services_lib o la libreria cardview_V7中的说明,同样的错误,但我使用以下方法解决了:
Your Project -> right click -> Properties -> Java Build Path -> Libraries -> Add Jar -> yourjar.jar