I am new to Android development and I want first to get the Hello World
application running.
I am using Eclipse IDE and the Android 4.0.3 version 15 SDK. I copi
I am using Android Studio 0.8.1. I have a project's gradle file like below:
android {
compileSdkVersion 19
buildToolsVersion "20.0.0"
defaultConfig {
applicationId "com.omersonmez.widgets.hotspot"
minSdkVersion 15
targetSdkVersion 19
versionCode 1
versionName "1.0"
}
buildTypes {
release {
runProguard false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
My emulator was android 4.0. So i modified my emulator and made api level 4.0.3(apilevel 15). It worked.
You will see the same error if you are trying to install an apk that was built using
compileSdkVersion "android-L"
Even for devices running the final version of Android 5.0. Simply change this to
compileSdkVersion 21
My solution was to change the run configurations module
drop-down list from wearable
to android.
(This error happened to me when I tried running Google's I/O Sched open-source app.) It would automatically pop up the configurations every time I tried to run until I changed the module
to android
.
You can access the configurations by going to Run
-> Edit Configurations...
-> General
tab -> Module: [drop-down-list-here]
Received the same error , the problem was difference in the version of Android SDK which AVD was using and the version in AndroidManifest file. I could solve it by correcting the
android:minSdkVersion="16"
to match with AVD.
I found that making the recommended change in the manifest didn't solve my problem.
The fix was found in the GradleScripts folder, in the build.gradle file for the Module:app.
Inside this file (build.gradle) the following line was modified. minSdkVersion 22 I changed this '22' value to '19' for my particular phone and the build completed without error.
I tried all the responses described here but my solution was changing inside my build.gradle
file minSdkVersion
from 8 to 9 because some libraries in my project can´t work with API 8, that´s was the reason for the message INSTALL_FAILED_OLDER_SDK
:
apply plugin: 'com.android.application'
android {
compileSdkVersion 22
buildToolsVersion "22.0.1"
defaultConfig {
applicationId "com.tuna.hello.androidstudioapplication"
minSdkVersion 9
targetSdkVersion 22
versionCode 1
versionName "1.0"
}
...
...
...