Hi,

I'm trying to create repeating alarms and I wan't know what's your best practices about it.

For repeating alarms, I use the following code. I create multiple alarms with different key for each one. I use the "in" parameter but it seems sometimes to have a strange behavior....

How would you do this a better way ?

Code:
for (incrementjour=0;incrementjour<=72;incrementjour = incrementjour + 24) {

	var params = {
		"wakeup": true,
		"key": "group1" + incrementjour,
		"uri": "palm://com.palm.applicationManager/open",
		"params": '{"id":"com.scienceapps.multipleapplauncher","params":{"message": "1"}}',
	}
	
		var timeoutValue = minutes;
		var timeoutValueHeure = heures;
		
		if ((timeoutValue + timeoutValueHeure*60) < 5){
			Mojo.Controller.errorDialog("Alarms must be set for at least 5 minutes in the future.");
			this.cbmodel.value="OFF";
			this.controller.modelChanged(this.cbmodel);
			return;
		}
		params["in"] = (incrementjour + timeoutValueHeure) + ":" + timeoutValue + ":00" ;	
		
	this.controller.serviceRequest('palm://com.palm.power/timeout', { 
		method: "set",
		parameters: params,
		onSuccess:  this.handleOKResponse.bind(this),
		onFailure:  this.handleErrResponse.bind(this)
	});
}