xTIMER TIME|SINGLE|REPEAT TIME|INTERVAL ON|OFF The xTIMER event uses the Amiga's timer.device to provide acurate, system friendly timming events. There is three ways you can ask to be notified : TIME - trigger event at the given time SINGLE - trigger event after given interval REPEAT - trigger event *every* given interval example : xTimer time 7:30 ON - event happens at 7:30 xTimer single 5 ON - event happens in 5 hours xTimer repeat 0:1:30 ON - event happens every 1 min, 30 secs ===========>>> Time format The time must be given as 24HOURS:MINUTES:SECONDS, i.e. 7 means 7 hours (use 24 hour notation) 7:30 means 7 hours and 30 minutes 0:0:30 means 30 seconds (could also be 00:00:30) - note : for separators you can use ':', '/', '-', or '.' ==========>>> SETGAD the xTimer ON|OFF : This Event can start as ON or OFF. When it starts as ON, the request to the timer.device is sent as the gui file is getting loaded - as soon as the parser reads the event. You can give it a @{" GADID " LINK "GadID"} and thereafter @{" SETGAD " LINK "SetGad"} Gui ID ON|OFF whenever you want. If you set it OFF (or when you quit the gui) if there are any pending timer requests they are aborted. NOTE : *every* time you SETGAD a timer ON the time request is issued again - even if the xTimer is type 'SINGLE'. The HIDE and SHOW keywords have no effect on timers. =========>>> Updating the xTimer : The @{" UPDATE " LINK "Update"} command can be used to change the time interval: Update gui id 10:30:25 This will have the following effect, according to the timer type : TIME - will set the time to be woken to 10:30:35 SINGLE - will wake you up in 10:30:25 hrs from the time you issue this setgad command - if there were any requests already issued they are cancelled. REPEAT - will wake you up every 10:30:25 hrs Again, all pending requests (for *this* timer) will be cancelled. ==========>>> Behaviour The Timer is as accurate as possible. However, Gui4Cli is a multi-tasking program and there may be something else going on when the timer event is triggered - maybe you're using the menus or have a ez-requester open, or commands are executing.. If this happens you will 'hear' the event *after* whatever you are doing finishes and Gui4Cli gets around to notifying you. If this happens in a REPEAT timer, and if while you are busy many such events happen (i.e. if you set the interval to 1 sec and many seconds pass while you are messing around with something) then you will hear only *one* of the events - i.e. the REPEAT events will *not* be stacked. ==========>>> Related stuff : See also the @{" $$SYS.TIME " LINK "iv_system"} related @{" Internal variables " LINK "Variables_Int"} Example (an alarm clock) : RUN gui - See Source