parsing error when install apk in android 11 - android

when I install my apk in devices with android 11, I get parsing error, but in another devices with lower android version, I have not this problem. how I can solve it?
my apk is very simple, it is just a web view with fcm packages and have not any special permission in manifest file.

Open your build.gradle file and you will see something like this
android {
compileSdkVersion 30
buildToolsVersion "30.0.3"
defaultConfig {
applicationId "com.yourapp"
minSdkVersion 19
targetSdkVersion 30
versionCode 11
Now you have to change the targetSdkVersion to 30 or above (only if possible).
Recompile and Install, I should work by now.
Still if it didn't work, include the error log in your question.

Related

Could not find method compileSdk() for arguments [30] on extension 'android' of type com.android.build.gradle.internal.dsl.BaseAppModuleExtension

I got the above error compileSdk() not found. While creating the app I have installed TargetSdk 31 and min SDK 19 But Apk does not install on Oreo Version so I have changed TargetSdk 31 to 31 and minSdk 19 to 16. I have uninstalled SDK 31 but it partially uninstalls. Please help me to solve this problem I am new to Android.
I have been strugling with this issue for hours until I looked at some older project. For some reason, newer versions of Android Studio mess up the directives from the Gradle file.
Just add "Version" after the name and it will work. So where you see "compileSdk" just rename it to "compileSdkVersion". You will probably also have to do that in "targetSdk" and so on.
in your <android_proj>/app/build.grandle instead of targetSdk 30 use:
android {
...
defaultConfig {
...
targetSdkVersion 30
}
}

My target SDK version is 25 but Google Play says app only supports 4.1-4.4 devices?

android {
compileSdkVersion 25
buildToolsVersion "25.0.0"
defaultConfig {
applicationId "com.abc.ege"
minSdkVersion 16
targetSdkVersion 25
versionCode 3
versionName "1.1.3"
vectorDrawables.useSupportLibrary = true
}
}
Although my target sdk version is 25, when I upload the apk to play store, it says "not compatible with devices with android version 4.4 and over, where is the problem?
edit: app works fine on emulators and there is no hardware access in manifest file
I think you should lowerize targetSdkVersion to 24, as 25 (7.1) is not released yet.
Solved the issue. Looks like an external library's android manifest file maxSDK is set to 19.

Apps are not supported in lesser than v5.0(lollipop)

In android studio, i have create new project that run on 2.2(that shows 100% compatibility). The project is about calculation. I have installed on my phone(lollipop), and the app is working properly. But, I tried to install in my friends kitkat phone, the app is installed but, When i open the app, that shows Unfortunately the app has stopped. So, I need a help. What I have to do?
Thank You.
May be you set Minimum SDK at Lollipop check it out in build.gradle file.
android {
compileSdkVersion 24
buildToolsVersion "23.0.3"
defaultConfig {
applicationId "com.communitynow.communitynow"
minSdkVersion 15
targetSdkVersion 24
versionCode 1
versionName "1.0"
}
and add
compile 'com.android.support:multidex:1.0.0'
in gradle file
Here in defaultConig{} minSdkVersion should be 15 or according to your minimum android run requirement.
You need to create a kit kat emulator to run the app on then check the log cat to see what the error is.

I want to developed one app upon API 17 but I haven't build tool version 17 so how it is possible?

Please help me regarding developing android app. If I developed that app upon API 21 or 23 then Is it run?
You don't need that version of build tool.
In the build.gradle, set minSdkVersion or targetSdkVersion (or both) to API-17. For your case below is recommended:
defaultConfig {
...
minSdkVersion 17
targetSdkVersion 23
...
}

Checking for backwards compatibility- an easier way?

I am about to release my first app and targeted lollipop when writing it in the hope that the uptake would of been greater by the time I was done. As well all know, it is still awful.
In my build.gradle I have this line:
android {
signingConfigs {
}
compileSdkVersion 21
buildToolsVersion "21.1.2"
defaultConfig {
applicationId "com.xxx.xxxx.toolbox"
minSdkVersion 21
targetSdkVersion 21
versionCode 7
versionName "1.15"
}
If I change the min SDK version to 19, the app will try and install on a device running API level 19. It crashes, but does not give me any feedback as to why (I have obviously used some methods from higher APIs). Is there any way to quickly figure out which methods I have used that need to be changed?
thanks,
Matt
If you set minSdkVersion to some version and recompile your application, Lint should automatically mark all instances where you use higher API as errors. That is, unless you annotate it with #TargetApi.
Also, if your application crashes, check LogCat. There will be an exception describing what went wrong and where.

Categories

Resources