报错:
Error:(58, 5) No resource found that matches the given name: attr 'android:colorAccent'.
原因:
用android 4.2 (compileSdkVersion 17 ) 的api进行编译
在创建项目的时候 build.gradle文件中自动添加依赖了v7包
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:23.4.0'
}
解决:
去掉 compile 'com.android.support:appcompat-v7:23.4.0'