How i can build and run my app in android studio - android

How can i resolve this? After building my app on android studio and running on my phone it works fine but when i share it to another phone it says "There was error parsing this package"

The problem is probably one of the following:
You set a minimum SDK version that is not supported in your friend's device. or maybe you added other restrictions in your app that prevents the APK from being installed on that device.
The APK you're trying to install is considered to be coming from an "unknown source", The Android system prevents you from installing apps from sources that are not known to the system.
To install that APK on your friend's device, you need to enable installing APKs from unknown sources, this setting is by default disabled and can be enabled from the device settings, on some devices you can find this option under Security settings, and on other devices it can be found under the Apps settings

Related

I cannot install .apk which have geneteted from AndroidStudio on my phone

As I have stated in the title I'm struggling with .apk I cannot install application on my phone I'm getting app not installed. But when installing via usb I'm able to install application on the emulator phone. It’s always showing App Not Installed on mobile phone.
When I run application via AndroidStudio to USB the application has been installed. I do not know where I should looking for issues. May be someone had the similat issue.
There are two things you can try:
First of all build your apk by Build/Build Bundles/Build APK and not just by creating apk as a side effect of simply running the app under Android Studio
Make sure no other flavors are installed on your device - sometimes devices offer "Uninstall for all users" - that's what you should be looking for.

React native app-release build not working for some android devices

I gave a build for android using gradlew assembleRelease.
but app-release.apk file not working for some devices like honor 9i, Redmi note 5 pro.
Make sure your app is compatible with OS of your device. Enable installation from unknown sources. Sign your app before sending .apk. It is important due to security restriction of some devices.
signing your app
Happened to me on some devices as well. Even if you allow installation from unknown sources turned on. Some devices alter the final .apk file (maybe for security reasons). So we used android playstore publish for distributing app as test/beta builds. Pick one appropriate for your pre release distro. It should work fine.

The application could not be installed: SHELL_UNRESPONSIVE -android studio 3.5

Installation did not succeed.
The application could not be installed: SHELL_UNRESPONSIVE
The device timed out while trying to install the application.
Retry
This happens when trying to install APK on a real device. the installation start then
showing on real device play protect prevention that the app is from unknown app's developer can harmful to your mobile.
showing to option below:
1.install anyway.
2.ok.
It may because your phone memory is full. you can delete some data from your phone and then try. for me it worked.

Android third party causes "app not installed" error

I have created with the use of android studio a small project and then I generated the signed apk. Then I tried to install it in three phones and in the first one (which has android 8) the app was installed successfully but in the second one (which has android 4.2) and third one (which has android 5) I got the "app not installed" error. This is my second app (project) and my first one has been installed successfully in all these three phones. The minimum SDK version of the app is Android 4.0.3 (API level 15), so that's not causing the problem. Can anyone guess where the problem is?
Sign the apk with both v1 and v2 signatures. this is the most likely culprit given your scenario. apk will not get installed on devices with less than marshmallow if you only sign with v2
Well you can try following:
Change install location of app on the phones it's creating problem.
Try resetting app preferences
Clear Data and Cache of Package Installer
Allow Apps from Unknown Sources (Go to Settings → Security → Unknown Sources. Enable Unknown Sources. And then try installing App)
Try Deleting .android_secure/smdl2tmpl.asec file from your SD Card if using SD card
Resign the app.
Try changing app codes by using some apk editor app

Unable to build xamarin project to real device

I am working on a Xamarin project (Visual Studio 2017). It's working fine in the emulator when run in Debug and Release mode but I am unable to run it in a real device as Visual Studio is not showing any attached device though device is already attached and also developer option and all necessary options are active.
I am also getting the following error when I try to make an APK and run it in a real device:
app not installed, package is corrupted
There can be several reasons for your issue that you don't see the device in the VS dropdown:
You have activated USB Debugging on your device but have not trusted the computer you're connecting to. Just try to deactivate and reactivate debugging. If a dialog appears that asks is you want to trust this computer, than this was your issue.
You have configured a minimum API Level / SDK Version for your app that is higher than the API Level of your device. So just check your Android version on your device and the version you've defined as minimum in your project settings
Regarding the "package corrupt" error, I can think of the following:
You have not signed your apk before you deployed it to the device. Just building the apk is not enough. There is an "archive" menu option in the context menu of your Android app. More info on that can be found here https://learn.microsoft.com/en-us/xamarin/android/deploy-test/release-prep/?tabs=vswin#archive-for-publishing
Build it in release mode. Debug builds aren't signed. Then make an archive and distribute it (ad-hoc-mode). This will create a signed apk. More info: learn.microsoft.com/en-us/xamarin/android/deploy-test/… – Andre Kraemer

Categories

Resources