[Local Notifications Plugin] No enum constant de.appplant.cordova.plugin.notification.trigger.DateTrigger.Unit.0
Forge component by OutSystems R&D
Published on 09 Dec 2020
Application Type
Service Studio Version
11.10.4 (Build 36716)

Hi, I'm trying to build a mobile app, that schedules local notifications. 

The problem is, that the app crashes (ends without a notice) as soon as I trigger the ScheduleNotifications Client Action.

Cordova and the LocalNotificationsPlugin return true for loaded and ready.

The dev monitor displays the following error for the crashes:

A fatal error has occurred. Please contact OutSystems support: No enum constant de.appplant.cordova.plugin.notification.trigger.DateTrigger.Unit.0 

The stack is:

java.lang.IllegalArgumentException: No enum constant de.appplant.cordova.plugin.notification.trigger.DateTrigger.Unit.0
at java.lang.Enum.valueOf(Enum.java:257)
at de.appplant.cordova.plugin.notification.trigger.DateTrigger$Unit.valueOf(DateTrigger.java:30)
at de.appplant.cordova.plugin.notification.Request.getUnit(Request.java:198)
at de.appplant.cordova.plugin.notification.Request.buildTrigger(Request.java:178)
at de.appplant.cordova.plugin.notification.Request.<init>(Request.java:75)
at de.appplant.cordova.plugin.localnotification.LocalNotification.schedule(LocalNotification.java:270)
at de.appplant.cordova.plugin.localnotification.LocalNotification.access$400(LocalNotification.java:62)
at de.appplant.cordova.plugin.localnotification.LocalNotification$1.run(LocalNotification.java:146)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:929)

I tried to republish and reinstall the App, but the problem remains.

I also tried to manually upgrade to Plugin Version 7.0.1 (including republish, rebuild APK, and reinstall App), but same error.

The data I submit with ScheduleNotification:

id: 1 (also tried other numbers, 0 and empty)
title: "Test1"
text: "Test2"
every: 0
at: CurrDateTime() (also tried empty, other dates and times)
badge: 0 (also tried other numbers)
sound: empty
data: empty

The mobile device I'm testing on: Huawei P30 Pro, Android Version 10, all updated

What am I doing wrong?

Thank you very much for any help or advice!

Best regards


Rank: #17

Hi Chris,

When you post a question on the forum you can also select the Forge component to which your question relates. This will help community members to understand your question better, resulting in more replies.

So maybe you can edit your post, or if that is not possible I can do it for you, but you will have to tell me which Forge component you use? Is it the Local Notification Plugin?



Rank: #44065

Is there anybody who might have an answer to that??

I'm really getting desperate :D

Rank: #22236

I have exactly the same problem.