I want your help in fixing this gradle sync error in my project that I made before reinstalling android studio. So far I have tried changing sdk and jdk path in settings and project structure.
I am attaching some screenshots below in no order:-
Build gradle in case:-
apply plugin: 'com.android.application'
repositories {
mavenCentral()
flatDir {
dirs 'libs'
}
}
android {
compileSdkVersion 29
lintOptions {
checkReleaseBuilds false
abortOnError false
}
useLibrary 'org.apache.http.legacy'
defaultConfig {
applicationId "com.mathon.fingers"
minSdkVersion 15
targetSdkVersion 29
multiDexEnabled true
versionCode 4
versionName "1.0.4"
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
}
You are using compileSdkVersion 29 but in the screenshot API Level 29 is not installed. So you can either install API level 29 or Just change "compileSdkVersion 29" to "compileSdkVersion 30".
Go to Android SDK, Select Android 10 (Q) and click Apply. This will fix your problem.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.