Timer in background

How to run timer in background forever, I know from iOS 12 app gets only 30 seconds after it moved to background but I want to run app forever in background

I want to run app forever in background

This is not possible in the general case. If you can explain your high-level goal, we may be able to offer alternative paths.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
Hi Eskimo,

Is there a way to run the timer in background for 3 minutes to logout from the server session? or is there any other possible approach to get an event after 3 minutes to perform logout while the app is in background?

Is there a way to run the timer in background for 3 minutes to logout
from the server session?

Can you start a new thread for this? It’s clearly a different question than Kaikili’s and, even though they never responded, I’d prefer not to hijack their thread (-:

Tag it with BackgroundTasks so that I see it.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Can't you just save the time when the timer started to core data or something and on app reopen fetch that and calculate time since for timer? That seems like an easier way.

And if you ever need to use the timer in background you can always fetch the date and calculate the difference fairly easily.

Timer in background
 
 
Q