Sub Service_Start (StartingIntent As Intent)
RECUP_alarme 'Récupère les variables dont notif, alarm et HeureAverto
If notif =True Then
Dim TheHeure As String
DateTime.TimeFormat = "HH:mm"
TheHeure = DateTime.Time(HeureAverto)
If alarm = True Then
Dim n As Notification
n.Initialize
n.Icon = "logo"
n.SetInfo("Contraception", alerte, "Main")
'Change Main (above) to "" if this code is in the main module.
n.Vibrate = True
n.Notify(1)
End If
StartServiceAt("",TheHeure + (60000 * 60 * 24) ,True)
'StartServiceAt("",DateTime.TimeParse(TheHeure),True)
'StartServiceAt("",DateTime.TimeParse(TheHeure + (60000 * 60 * 24) ),True)
Else
CancelScheduledService("")
End If
End Sub