Hi all .
I have an app that is supposed to run 24/7 .
But i think OS is killing it .
I have setup the tablet ( Samsung ) with appropriate settings ( battery savings etc ) .
The tablet is always on and connected to power .
And i have taken part of code that i found here on the forum to prevent app from closing .
Fx I have put in these lines:
And i have tryed to change things here and there but it still keeps turning my app off.
Is there anything to do to prevent Android from killing my app ?
Or shall i restart app by timer or anything else .
Br
Nizze
I have an app that is supposed to run 24/7 .
But i think OS is killing it .
I have setup the tablet ( Samsung ) with appropriate settings ( battery savings etc ) .
The tablet is always on and connected to power .
And i have taken part of code that i found here on the forum to prevent app from closing .
Fx I have put in these lines:
Code:
Service.AutomaticForegroundMode = Service.AUTOMATIC_FOREGROUND_ALWAYS
DontSleep.PartialLock
DontSleep.KeepAlive(True)
And i have tryed to change things here and there but it still keeps turning my app off.
Is there anything to do to prevent Android from killing my app ?
Or shall i restart app by timer or anything else .
Br
Nizze