RH Timer

Timer RH

+

AppleScript

AppleScript

How to add a timer?

Use the command add timer "{value}"

tell application "Timer RH"
    add timer "15m Break #green"
end tell
                

The value syntax is the same as on the main window of Timer RH app.


also you can specify label and color separately from timer value

tell application "Timer RH"
    add timer "10:00" label "Meeting" color blue
end tell
                

If everything is ok, the command will return the identifier of the new timer.


to add a stopwatch:

tell application "Timer RH"
    add timer "stopwatch Work #red"
end tell
                

Need to wait until the timer expires?

Use the command wait to {state} of timer with id {timer id}

tell application "Timer RH"
    set timerID to add timer "15m Break #green"
    with timeout of 24 * 60 * 60 seconds
        #{...}
        wait to fire of timer with id timerID
    end timeout
end tell

How to manage the timer?

The following commands are available: pause, start, restart, cancel.

tell application "Timer RH"
    set timerID to add timer "10AM Task XL #yellow"
    #{...}
    pause timer with id timerID
    #{...}
    start timer with id timerID
    #{...}
    restart timer with id timerID
    #{...}
    cancel timer with id timerID
    #{...}
end tell

Need something else?

Any questions or suggestions send to my email: support@3bitlab.com

Thank you for using
RH Timer