I'm porting my app from Android to iOS using LiveCode V6.6.5 and I'm running into an issue getting Local Notifications to work on iOS V8.1.
Based on the Dictionary, the two system should use exactly the same parameters to create a local Notification and it is working just fine on Android. Here is my code.
Code: Select all
function scheduleLocalEvent pType pTime pMessage pAlertDate pAlertTime
   
   -- Create Local Notification Payload which has multiple elements to be used by the localNotificationReceived handler
   put pType & "|" & pAlertDate & "|" & pAlertTime & "|" & pMessage after tEventPayload
   -- Create the Notification
   if environment() is mobile then
      mobileCreateLocalNotification pMessage, tEventTitle, tEventPayload, pTime, "True", 0
      put the Result into tNotificationID
      put "New Alert" && tEventTitle && pTime && tNotificationID & return after fld "debug" on card "Events"  -- DEBUG
     end if
   if tNotificationID is not an Integer then
      logSaverError "Invalid Notification ID=" & tNotificationID & "for Event:" & tEventTitle
   end if
   return tNotificationID   
end scheduleLocalEvent
Is there something special that I need to set up in iOS to allow the application to use Local Notifications?
I DO NOT have Push Notifications enabled in the app. Is that a problem?
Thanks for the help
DCP
