Reputation: 11
I am new to iOS programming, and I face a real problem while developing a Newsstand App. Simply, the app seem not to receive Newsstand notifications (I have NSLog in didReceiveRemoteNotification and in didFinishLaunchingWithOptions and no log is presented during application running in XCode). I set all the needed settings in info.plist, I also included this in my app:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
// register for Push notification and don't use throttling for development
//[[UIApplication sharedApplication] unregisterForRemoteNotifications];
[[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"NKDontThrottleNewsstandContentNotifications"];
[[NSUserDefaults standardUserDefaults] synchronize];
[[UIApplication sharedApplication] registerForRemoteNotificationTypes:UIRemoteNotificationTypeNewsstandContentAvailability];
As the app is able to process normal Push Notifcations (alert, sound etc.) I assumed it is all about throttling, but, as I mentioned above, I set the defaults not to use throttling. I have read some Apple's guidlines and have searched through many forums and found out that I need to set the device I'm working with to "enabled for development" in XCode organizet. However I cannot find any checkbox or button to set it. I use XCode 4.5.
Can anyone help me on the issue? Do you have any idea how to debug notifications and check where they dissapear?
Upvotes: 1
Views: 555
Reputation: 113
You have to send the push notification with content-available : 1 and set the Automatic Downloads to 'ON' in the Newsstand setting of your app in your device.
Upvotes: 1