alarm command

The alarm BASIC program schedules a task at a given time, or after a given delay in seconds, at a given date.

For Windows: Not Supported


alarm {delay|hh:mm{:ss}{,date|*}{command}}{(options}


date Defaults to current date if no date is specified. If an asterisk is used as a date, the command executes every day at the specified time
  • If the command is not specified, options apply to the alarm command itself.

  • If the command is specified, the options are part of the command.

  • If the command starts with an asterisk, it is assumed to be text, which displays on the user’s terminal when the alarm expires.

  • If no option or command is specified, the Update processor is entered to add, change, or review alarms.

options c Cancels all currently scheduled tasks for the user.
l Lists the currently scheduled tasks for the user.
s Sets the current alarms. This option rearms the alarm. It should be included in every user macro to start the alarm every time a user logs on.
Warning: Before alarm can be used, alarm (s must be run on the dm account, to create the file alarm.file. This file is created as a dx-type D-pointer, and is not saved on any save-class backup.

The alarm signal handler must be set to useralarm by the trap command.

If an input with time out is done after the alarm has been set, the alarm is suspended for the duration of the wait and restarted for whatever remaining time. Any command which should have been executed during the wait is postponed until the input with time out is done.

The alarm is run by the current process. If an event should have been executed while the process executes a TCL sleep command, it is cancelled. If an alarm occurs while the user is logged off, it is discarded.

The alarm can run as long as the process is not disconnected. To be sure, however, the alarm (s command, without any argument, should be included in the user macro to restart the alarm every time the user logs in.

If the alarm handler is not set properly, the alarm will not run. For example:

alarm 5 which
Next event at 14:28:00, 01/09/03 "which"
alarm: Alarm signal handler is not set. Use ’trap alrm useralarm’ to set it.

The trap handler can be set by the command:

trap alrm run dm,bp, useralarm


Sets an alarm for 18:00 (6:00 PM) today. At this time, if the process is still logged on, the message File save is starting displays on the user’s terminal.

alarm 18:00 * file save is starting

In 120 seconds, the process logs off. This command can be included in a Proc, to make sure an input screen does not wait for an input. When the input is complete, alarm (c clears the time out.

alarm 120 off

At 9 o’clock, on December 3, meeting time displays.

alarm 09:00,12/03 display meeting time

Every day, at 17:00, the message command executes.

alarm 17:00,* msg * file save in 30 minutes

Enters the Update processor to edit the user alarm item.


Lists the currently scheduled events.

alarm (l

Displays the next scheduled event, and starts the alarm. This command should be included in the users’ macros, so that the alarm is refreshed every time a user logs on.

alarm (s