uilocalnotification is not firing at exact time

后端 未结 3 1173
难免孤独
难免孤独 2021-01-14 06:36

I want to implement uilocalnotification in my app. but the problem is that it is not firing at the exact time. it is firing after 30 - 40 secs from the given fi

3条回答
  •  南笙
    南笙 (楼主)
    2021-01-14 07:25

    I know this is an old question, but I have just figure this out, you can use the dateByAddingTimeInterval : method.

    notif.fireDate = [[datePicker date] dateByAddingTimeInterval:-30];
    

提交回复
热议问题