1. You should use B4XDialog with B4XDateTemplate.
2. Why is Alarm set to be string? It should be Long
3. All of these calculations are not needed.
You should replace them with:
Code:
StartServiceAt(AlarmService, (Alarm, True)
Scheduled services are removed when the device is restarted. It is a bit optimistic to expect the device to keep running until 2025.