Notification Sound did not come when app is in foreground swift error


Notification sounds are not played when the app is in the foreground.If you want to handle that then you can use a audio player to play the sound manually when the app gets the notification.You can handle in app delegate method when receiving notification


    func notificationHandling(notification:UILocalNotification) {
}

The above method will be called when the notification came.Inside of the method you can get the notification values and process those values.

    Comments

    Popular posts from this blog

    Invalid bundle error while upload the app to the app Store

    Convert NsNumber, NSDate to String in iOS Swift

    Global LocationManager Singleton class iOS Swift