Progress
Programming
Handbook
ENABLE/WAIT–FOR Processing
The END–ERROR key modifies its behavior yet again depending on whether input is blocked by a WAIT–FOR statement or any other input blocking statement, such as UPDATE. The
p-error5.p
procedure shows the difference:
Within the DO block of UPDATE statements, END–ERROR works as explained earlier. That is, for an UPDATE statement, END–ERROR on field a acts like ENDKEY (leaving the block) and on field b acts like ERROR (retrying the block and displaying the RETRY message).
However, in a similar DO block, where input is enabled with the ENABLE statement and blocked with the WAIT–FOR statement, END–ERROR always works like
ENDKEY. It always leaves the block when entered for field a or field b. Progress treats END–ERROR differently in this case, because the WAIT–FOR statement is designed to control input in a more random and less modal fashion than the UPDATE statement. In an event-driven interface, the triggers for each widget are generally responsible for handling error input for that widget. Thus, END–ERROR as ENDKEY. provides a consistent way to exit the interface from any input widget.
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |