I have a set of contacts that can be synched from my ios app to device address book. When the user deletes the app from the device, I want to remove those contacts from device address book as well. But as far as I know, Apple does not provide a way to find out it programmatically. Can anyone guide me on this?
Asked
Active
Viewed 75 times
1 Answers
2
There's no way an app can do something before being removed.
When a user deletes an app from a device the app does not get any notification or additional processing time. It is just terminated immediately with a SIGKILL
.

Nikolai Ruhe
- 81,520
- 17
- 180
- 200
-
Is there any way to get any kind of notifications to the app in background, so that we can do necessary things before the app get deleted from device? – JamesDon Oct 05 '15 at 08:14
-
@JamesDon As I said, the app will not be notified and it would not get the chance to run any codes before deletion. This is very likely by design and probably difficult to circumvent. – Nikolai Ruhe Oct 05 '15 at 08:21
-
But when we sync contacts from our mail client(eg: gmail) to device, we will be able to view the synced contacts in device address book which will be removed from the same, when we delete the mail account. May I know how it's working then....Can't I get something like that implemented in the App? Please correct me if I am wrong. – JamesDon Oct 05 '15 at 10:01
-
@JamesDon That's because Apple supports contact syncing from various account types in the OS. Apps can't do that. – Nikolai Ruhe Oct 05 '15 at 10:56