When I install my iOS application using Xcode for the first time, my iPhone asks whether I want to enable push notifications.
I am able to send a notification, and the badge shows a number that I sent.
When I delete the application from my iPhone and rebuild it in Xcode and reinstall it again on my iPhone (using Xcode):
- The device does not ask if I want to enable push.
- The badge is there and remembers the last number.
I tried the same application on a fresh device (installed the IPA) and it asked me for permissions.
How can I completely make my device forget the application?
There is a workaround for this that involves setting the system time ahead by two days, rebooting the device, and then changing the system time back to the present. iOS is designed to only ask permission for push once a day per application.
http://developer.apple.com/library/ios/#technotes/tn2265/_index.html