Calling A Method At Specific Time Every Day

前端 未结 3 1915
臣服心动
臣服心动 2020-12-06 08:34

My app runs constantly in kiosk mode. Once every 24 hours at a specific time I need to sync some data from core data to a web service.

I know how to do the sync p

3条回答
  •  失恋的感觉
    2020-12-06 09:07

    A simple solution is just to set NSTimer to check current date every minute (or every second, for example). If the current date is greater then required, then fire the method and update the required date.

提交回复
热议问题