Incorporating conditions into alarm

Hello,

I currently use

$if(si(alarmon)=1, "Alarm," + df(" hh:mma", si(alarmd)))$

which shows my alarm, given that it is turned on. May I ask how to incorporate a condition so that when it is on, it shows

Alarm, 06:00AM

and when it is off, it shows

Alarm, off <-- or any self selected text for that matter

Appreciate any help given for such a trivial question.

Thanks!

Sure, just do

Alarm, $if(si(alarmon), df(" hh:mma", si(alarmd)), "off")$