How to fix loading issue with flutter app on apk release - android

I am building a flutter app. I use Getx State Management. I fetch the data from internet using Getxservices
The app works fine on debug but I face this issue on apk-release. First when I install the app on android phone, it will work perfectly like this:
But when I close the app and re-open it, I will have a screen like this:
Below is my AndroidManifest
The app works fine on debug mode so there is no way I can debug it to know the exact thing causing the issue.

Give internet permission in your AndroidManifest
<manifest xmlns:android="...">
<uses-permission android:name="android.permission.INTERNET"/>
</manifest>

I have gotten the solution. I added splash screen and loaded all my resources on splash screen and the issue is gone.

Related

Removing Nativescript application from a device, Application Settings

I am having trouble with a Nativescript App which use the Application Settings Module,
When i remove this App from an Android Phone, even if i clear App Data and Cache before uninstall, and i reinstall it, the settings set earlier (before unistall) seems to be still there,
Does anyone else has ever encountered this issue ?
Regards,
Kansen
<application
android:allowBackup="false">...</application>
Try this in AndroidManifest.xml

How to deploy an app to mobile after adding AndroidManifest.xml to Project

My problem is, that I can't seem to deploy my app to my phone (galaxy s4) or the emulator anymore, after adding the AndroidManifest.xml to the project.
I have been working on this app for 1 or 2 days, never had a problem testing it on my phone. I wanted to add the App Icon and change the app display name and found out that it had to be done over the AndroidManifest.xml file. So after finally finding where to add it in the QtCreator, I added an Icon and changed the name. When I click deploy, it loads and then the bar turns red, without ANY error messages or nothing. It just goes red full and then goes away. Even the warnings from build are not even showing.
I hope you guys can help me, this is my first question, so if I forgot any information or asked the question wrong, please let me know :)
You need dirqml2sdk debugger libaries (if your OS is windows). You can download it from here.

No content provider found for permission revoke - Android

i have a weired problem.
I want to install a app that i made on a Nexus 5 Phone and getting the LogCat error that i postetd below.
The funny think is, if i install this app on my Samsung Galaxy S3 it works fine. Just on my nexus 5 i get those errors and warnings.
And maybe i have to mention that the same OS is installed on both phones, CyanogenMod...
LogCat
http://pastebin.com/5dqdkKPY
android manifest:
http://pastebin.com/rtkeyVw5
Thanks for your help!
I think the reason is you lack of permissions. try add this code to your AndroidManifest.xml:
<uses-permission android:name="android.permission.INSTALL_LOCATION_PROVIDER"/>
Every major android component must be declared appropriately on your applications manifest file. It seems like you are using a Content Provider. Is it a provider you implement? Or is it one of the Android's build-in? In any case you have to declare your "intentions" at the manifest. Take a look here:
http://developer.android.com/guide/topics/providers/content-provider-creating.html#ProviderElement

Unfortunately app has stopped in Android Emulator

I am new to Android and I am trying a few small apps (like Compass). When I run the app in the emulator, it gives the message Unfortunately, Compass has Stopped.
I have no compile time errors.
How do I solve this, and what is causing this?
Thanks in advance.
I had the same error message and found that, in commenting out uses-permission nodes in AndroidManifest.xml I had commented out one that was needed. When I put it back in the app ran fine. I was able to reproduce the error. I needed:
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
This was for a barebones index.html, single page app, that displays Hello World.
And the permission above was the only one I needed to do Run As/ Android Application and get it to run in an emulator.
HTH
You have posted no code so it's difficult to see what your problem is. However I had the same issue which has been sorted out here Unfortunately HelloListView has stopped
It probably due to the fact that you don't have accelerometer and magnetic field support.
Go to your AVD configuration and add the following hardware: Magnetic Field Support and accelerometer
First check your AndroidManifest.xml file and write activity tag
For example, you have DisplayMessageActivity.class and package is me.user_interface
tag is:
<activity android:name="me.user_interface.DisplayMessageActivity"/>
You can write this after </activity> tag in AndroidManifest.xml file. Check the path carefully.

Android error: Application is not installed on your phone?

I am learning this via Sams Teach Yourself Android in 24 hours.
This is really strange, I run the app in the emulator and I get my splash screen (just some crappy text really) then I press the home button, and click on my app's icon and it gives me "Application is not installed on your phone"
I went into the emulators settings->applications and it's there!
I cleaned the project, uninstalled it from the emulator and re-ran it. Same damn problem.
(project is simple:
6activities, each has a unique text, as it starts it shows the splash activity
I have not even connected the other activities... just this)
You can download the entire source if you want at http://elxotica.com/TriviaQuiz.rar
Ok, got it working after going to the authors website, downloading the support code and going over it and comparing it line by line.
Basically in my manifest file I had
<activity android:name=".QuizSplashActivity"
android:label="#string/app_name">
and again below I had
<activity android:name="QuizSplashActivity"></activity>
which I thought was needed, but it looks like that should not be declared twice.
I fixed the problem but am not 100% sure of the cause :((
My problem was solved with this error when I moved the INTERNET permission statement in the manifest file out of the activity definition and into the application definition - that is, up in the hierarchy, right under the SDK version declaration:
<uses-sdk android:minSdkVersion="14" />
<uses-permission android:name="android.permission.INTERNET"/>
<application android:icon="#drawable/icon" blah blah
I also had the permission defined twice. Compiling did not find the bug, however, running the app on the Android emulator did. "Application not installed" is not very helpful, tho. Rather like, "You fowled up [and if you don't know why, I'm not telling you].
I have no problem to run it on Android 2.2 Virtual Device. Maybe you can try create new AVD and run it there. I´ve had similar problem with new update and creating new AVD solved it...
Yeah, I had the same problem.
Just don't declare QuizSplashActivity twice.
Helped in my project, grettz
Yet another failure mode with the same symptom. I had same permission twice, first like this:
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"></uses-permission>
then like this:
<application android:icon="#drawable/icon" android:label="#string/app_name" android:permission="android.permission.WRITE_EXTERNAL_STORAGE">
The second one turns out not only not needed, but also cause the "Application not installed.." error.
So my application declaration looks like this now:
<application android:icon="#drawable/icon" android:label="#string/app_name">
And all is well in the world.
Same symptom, different cause. I'm not entirely certain what happened, but I will hazard a guess in case it helps anyone. What I know for sure: I deleted the icon, dragged it anew from Applications, problem solved.
At some point I changed which Activity was the entry-point (had android.intent.category.LAUNCHER & android.intent.action.MAIN)
I was trying to open the app using an icon on one of my "desktops", an icon which I had added before making the change in the manifest which changed which Activity was MAIN. So I'm guessing that the shortcut refers to the launcher activity and not the app (makes sense)...
My problem was missing assemblies in the package. But only on some phones.
I enabled "link all assemblies" option in the Xamarin studio and problem solved.
Android project options->Android build->Linker behavior->Link all assemblies.
[I'm using Xamarin studio with mono on Android.]

Categories

Resources