[lamw]App to runs permanently: How to lazarus / 43-Android ---------------------------------------------------------------------- Luigi · 2018-03-19 18:30 Hello, I developed an app to control every hour if do anything, but the app can closed by press the X in the list of recent apps. How I can runs the app as a service or in background? I needs a GUI interactions with users. Thanks ---------------------------------------------------------------------- Thaddy · 2018-03-19 19:44 You mean an app that can't be closed? Impossible on Windows and Unix and Mac. On these platforms any process can be murdered. Does not matter if it is a service or daemon. It depends on rights. Give the proper rights or limit the rights. ---------------------------------------------------------------------- Luigi · 2018-03-19 20:02 I need, in android phone, my app must show a message every hours. But is quite simple to close the app. I need to run my app as a service or in background, what I do? Thanks ---------------------------------------------------------------------- Luigi · 2018-03-19 20:08 I need that my app is like whatsapp that runs ever, even it is closed or in background. Thanks ---------------------------------------------------------------------- jmpessoa · 2018-03-21 05:34 Hi Luigi, about, there are AppIncommingCallWidgetProviderDemo1 and AppSMSWidgetProviderDemo1 in folder "....demos\GUI" ---------------------------------------------------------------------- c4p · 2018-03-21 07:40 I think he means the way Whatsapp runs forever in the background and not the functionality of Whatsapp. You would need something like a watchdog/daemon/service that would respawn every x secs/minutes if it notices it's not running? start app on phone bootup etc. BroadcastReceiver/Intent and permissions to start the app on boot? Quote from: Luigi on March 19, 2018, 09:08:13 pmI need that my app is like whatsapp that runs ever, even it is closed or in background. Thanks ---------------------------------------------------------------------- Luigi · 2018-03-22 14:27 Quote from: c4p on March 21, 2018, 08:40:17 amI think he means the way Whatsapp runs forever in the background and not the functionality of Whatsapp. Yes, you understand my problem. QuoteYou would need something like a watchdog/daemon/service that would respawn every x secs/minutes if it notices it's not running? start app on phone bootup etc. BroadcastReceiver/Intent and permissions to start the app on boot? What I do to deploy my app who starts on phone boot? I tried to run my app and I notice that my app works correctly even in background, but my app is quite simple to stop working because it can kills by recent apps. Often my app is accidentally closed from recent apps Then I search a way to modify/rewrite my app to runs like a service but service not have gui functionality. I need GUI functionality to interact with the users for get some parameters  Thanks.