MSM-Workstation
Macros

Go back to the alphabetic list of macros
Go back to the first page of this tutorial

%%EvSequence

This macro generates code that returns a specification of the value of a property of the most recent event.

The property for which the value is returned by this macro is the sequence number of the event, which is equal to ^$Event("SEQUENCE").

Typically, one doesn't worry very much about the sequence in which the events occur: the events happen when the end-user manipulates the mouse and the keyboard, and the various pieces of "action logic" are executed when the corresponding events happen.

On occasion, one might wish to record some or all of the events, and keep track of the sequence in which they occurred.

Examples

Assume that an application wants to keep track of certain events. In the "common code" section, a subroutine is included:

log(event,text) ;
 Set ^log($j,%%EvSequence)=event_": "_text
 Quit

and several pieces of "action logic" start with:

Set remind=...
Do log(%%EvType,remind)

See also

%%EvChoice, %%EvControl, %%EvElement, %%EvKey, %%EvNext, %%EvPrior, %%EvPtrButton, %%EvPtrPos, %%EvPtrState, %%EvType and %%EvWindow.