问题描述
升级到Android Studio 1.3.1昨天,在构建项目时获取此错误,我无法创建一个新项目.添加错误和build.gradle文件:
alredy尝试将compileSdkVersion和buildToolVersion更改为21.
推荐答案
支持库的每个主要版本,例如您正在使用的23.0.0 appcompat,按照相同数字的API级别编译:即,API 23,按来自appcompat开发人员的g + post.因此要使用23.0.0,您必须将compileSdkVersion更新为23.
注意这与定位 api 23完全不同(可以单独完成,并且使用运行时权限模型是必需的).
问题描述
After upgrading to Android Studio 1.3.1 yesterday, Getting this error when building projects, I cannot create a new project. Adding error and build.gradle file below :
Alredy tried changing compileSdkVersion and buildToolVersion to 21.
推荐答案
Every major revision of the Support Library, such as the 23.0.0 AppCompat you are using, compiles against the API level of the same number: i.e., API 23 as per this G+ post from the AppCompat developer. Therefore to use 23.0.0, you must update your compileSdkVersion to 23.
Note this is completely different from targeting API 23 (which can be done separately and is what is required to use the runtime permissions model).