E edgar_ortiz Active Member Licensed User Longtime User Feb 5, 2017 #1 Hi, I read a little in the forum and I don't how to TRY to keep alive my app... specially when user sweep to close the app. I found: "Service_TaskRemoved" in "Starter" Service... but I don't figure what to do. Any idea is welcome Regards, Edgar
Hi, I read a little in the forum and I don't how to TRY to keep alive my app... specially when user sweep to close the app. I found: "Service_TaskRemoved" in "Starter" Service... but I don't figure what to do. Any idea is welcome Regards, Edgar
Erel B4X founder Staff member Licensed User Longtime User Feb 5, 2017 #2 Service_TaskRemoved will not help. 1. Create a foreground service (not the Starter service). 2. Use StartServiceAt to schedule your service to start every 5 minutes. See this example: https://www.b4x.com/android/forum/threads/custom-websocket-based-push-framework.40272/#content Note that on some devices, swiping the app from the recent apps list always kills the process and prevents it from starting again until the user launches the app. Upvote 0
Service_TaskRemoved will not help. 1. Create a foreground service (not the Starter service). 2. Use StartServiceAt to schedule your service to start every 5 minutes. See this example: https://www.b4x.com/android/forum/threads/custom-websocket-based-push-framework.40272/#content Note that on some devices, swiping the app from the recent apps list always kills the process and prevents it from starting again until the user launches the app.