6

As the title suggests, I'm interested to discover what Android does with PendingIntents created by an application which has been removed from a device.

My research so far involves setting an alarm using AlarmManager and a pending intent. In the normal case all works as expected. To test the uninstall case I set up an alarm for some point in the future with the AlarmManager and a PendingIntent and then remove the app. What I observed is that nothing appears to happen - logcat shows no errors from my PendingIntent trying to launch a use a missing class for example.

I can't find an documentation on this so would like to know if anyone has knowledge on this or a link I can refer to.

Mat
  • 202,337
  • 40
  • 393
  • 406
barry
  • 4,037
  • 6
  • 41
  • 68
  • I think they are deleted as well. Everything related to your package gets delete. But yeah, there's no docs about it, or perhaps I haven't looked hard enough. – Kumar Bibek May 30 '12 at 10:44
  • I was wondering the same. I have a repeating alarm which might be never canceled. So I hope android cleans the pending intent and related at the uninstall... – FabiF Sep 12 '12 at 08:15

1 Answers1

0

As my knowladge pending intents are run even if the application exit, but application remove using uninstall there is no way to run this pending intent because application cache directory and app data are removed ,pendingIntent

UdayaLakmal
  • 4,035
  • 4
  • 29
  • 40