2015-10-15 45 views
2

我剛剛創建了一個項目。這是我得到的第一個頁面。帶有117個錯誤的Gradle構建完成(Android Studio 1.4)

錯誤是這樣的

Error:(6, 21) No resource found that matches the given name: attr 'android:textAlignment'. 
Error:(10, 21) No resource found that matches the given name: attr 'android:paddingEnd'. 
Error:(10, 21) No resource found that matches the given name: attr 'android:paddingEnd'. 
Error:(13, 21) No resource found that matches the given name: attr 'android:paddingStart'. 

on gradle console following error occurs 
AGPBI: {"kind":"error","text":"Error retrieving parent for item: No resource found that matches the given name \u0027android:TextAppearance.Material.Inverse\u0027." 

AGPBI: {"kind":"error","text":"Error retrieving parent for item: No resource found that matches the given name \u0027android:TextAppearance.Material.Large.Inverse\u0027." 
and many more. 
+0

檢查你的builde.gradle文件在依賴部分。確保您已正確添加支持庫。 –

回答

0

更改構建工具版本。 如果您的Android版本是1.0或1.01,則應該嘗試在較低版本上構建API 21或更低版本。

+0

的確的確如此。感謝信息。 –

2

安置自己的builde.gradle。而我想改變你的buildToolsVersion

compileSdkVersion 23 
buildToolsVersion "23.0.0" 

defaultConfig { 
    // applicationId "package name" 
    minSdkVersion 17 
    targetSdkVersion 23 
    versionCode 1 
    versionName "1.0" 
} 

或設置buildToolsVersion to 23.0.1