문제

The app has local notifications in the notification manager. Is it possible to change text of already existing local notifications (e.g. the notification text had a mistake and I want to correct the existing messages)?

도움이 되었습니까?

해결책

While it is not possible to directly edit the notification, you may

  1. Get the array of scheduled notifications
  2. Create a mutable copy
  3. Create a new notification based on the one you want to modify
  4. Insert the notification
  5. Remove the old notification
  6. Set this new array as the list of scheduled notifications

You may of course combine 4.+5. by replacing the object.

다른 팁

NO. A notification in the notification manager can not be changed.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top