Can't get rid of scheduled push notifications - iOS - ios

I have a very silly problem, which I unfortunately don't really understand how to solve.
I'm trying to implement push notification to my iOS app (Swift). I did succeed to create scheduled push notifications, where I send a notification every minute, for test purposes. Now I don't seem to be able to remove this, even though I have removed the code related to it, and reinstalled the app on the device. The only thing working is to disable push notifications in Xcode, which I do not want to do. It seems like I have missed something fundamental about the concept.
I did use an APN Tester at first to send messages to the device, but I don't think that has to do with anything.
Silly question, but I hope someone could help me.
Thanks!

Use this to remove all local notification:
UIApplication.sharedApplication().cancelAllLocalNotifications()

Updating Lumialxk to be current as of Swift 4.0 using UNUserNotificationCenter
UNUserNotificationCenter.current().removeAllPendingNotificationRequests()

Related

Using push notifications on Heroku

I am looking for the simplest way to use push notifications to users from a Parse-Server app on Heroku. Just in case, this is for an iOS app.
Any tip or suggestion would be appreciated.
I used have code working on parse.com. But it does not seem to be working any more.
Have a look on this hope it works Traversy media PUSH Notification
He shows on pc i think this might work on mobile also ,if not the library he is using must have your solution

GCM push is not received on iPhone 7

My app uses GCM to send push notifications and it all worked great.
Recently, one of subdcribers bought iPhone 7 and wrote to me, that push notifications dont work.
I've checked the logs from GCM - message is sent correctly:
{"multicast_id":6854913573879465744,"success":1,"failure":0,"canonical_ids":0,"results":[{"message_id":"0:1484614306664165%6a57bb166a57bb16"}]}
She does receive other notifications from facebook, viber, etc., so no trouble with network.
Notifications are enabled in general and for my app.
"Do not disturb" is off.
Other subscribers with iOS 10.2 successfully receive notifications on their iPhones 5/6.
Reinstalling the app didnt help. App successfully receives the token, but doesnt receive notifications after.
What else can I check? Thank you.
I think this is a common issue on iPhone7. Check it here. I guess you have done all the workarounds in the link given but still no luck to fix the issue. Maybe this thread might help. Suggested action is to make sure that on your project settings, under the Capabilities Tab, scroll down to Push Notifications and turn it to ON. This automatically generates an entitlements file that contains the key APS Environment.

IOS9 Push notifications dialog appears after delete and launch app with xCode7

I have an application, it uses APNS, so I have code that subscribes to notifications, and everything works fine. But every time I reinstall app, and run it with xcode, I get allow push notification dialog. Every time.
I found hundreds questions about how to achieve this dialog again, but none - how to stop achieving them. I need help!
It's seems known IOS9 bug, here is a link for developer forum and still no response from apple and no solution:

Parse Client Push Notifications Not Working

I am trying to set up push notifications for my new app. I am getting the following error from Parse. Is everyone having the same issue? Is there a work around it?
Push notification is working for my other apps.
Ok - This is weird I was able to fix it by changing the name of my app. Not sure why this worked, but it worked.

IOS push notification break point

I use phone-gap plugin for APN and xcode 5.
https://github.com/phonegap-build/PushPlugin
I put a breakpoint at each function in the plugin.
For some reason when i send a push notification not even single break point are hit.
But the notification received on my device.
Any explanation for this.
Thanks in advance.
There are some things you could check:
Did you set them in in xcode or in the safari debugger? Actually I am not sure if the first option would ever work at all. Have any breakpoints worked in your application?
Is the app running in the foreground when the notification is received? As far as I know, no code is executed on receiving the message if the app is running in the background, so this might also be a reason for not hitting any breakpoints.

Resources