I created a new project in android studio and choosed target minimum SDK then after creating new project how can i change minimum target SDK in android studio?
Asked
Active
Viewed 5,432 times
0
![](../../users/profiles/397817.webp)
Stephen Kennedy
- 16,598
- 21
- 82
- 98
![](../../users/profiles/6591743.webp)
Harsh Trivedi
- 3,863
- 3
- 9
- 14
-
1check this answer https://stackoverflow.com/a/20167880/3983054 – King of Masses Feb 14 '18 at 13:52
-
1Please search for similar answered questions before asking your own – Dumbo Feb 14 '18 at 14:24
2 Answers
0
Update the gradle script of your module. Under the Gradle Scripts, the file is shown as build.gradle (Module : app). Not the build.gradle (Project : nameofproject)
this is an example of gradle file
apply plugin: 'com.android.application'
android {
compileSdkVersion 22
buildToolsVersion '25.0.0'
defaultConfig {
applicationId "com.project"
minSdkVersion 18
targetSdkVersion 22
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
change the minSdkVersion, to the desired one.
sync gradle and clean your project.
![](../../users/profiles/4878386.webp)
Zaher Hamadeh
- 1
- 1
0
Upgrade your build.gradle file by changing minSdkVersion to whatever version you want: for e.g minSdkVersion 18
![](../../users/profiles/4155898.webp)
Clapa Lucian
- 430
- 1
- 5
- 14