Article

What does the STOP-AFTER expression do?

Information

 
Article Number000064527
EnvironmentProduct: OpenEdge
Version: 10.x, 11.x
OS: All supported platforms
Other: N/A
Question/Problem Description
What does the STOP-AFTER expression do?
Steps to Reproduce
Clarifying Information
Error Message
Defect/Enhancement Number
Cause
Resolution
The STOP-AFTER phrase specifies a time-out value for a DO, FOR, or REPEAT block. The integer expression specifies the number of seconds each iteration of a block has until a time-out occurs. If a time-out occurs, the AVM raises the STOP condition and default STOP condition handling occurs. Use an ON STOP phrase on the block (or an enclosing block) to alter the default STOP condition handling.

The following example time-limits a procedure call using a RUN statement:: 
 
DEFINE VARIABLE cnt as INTEGER INITIAL 0.
PROCEDURE bumpCnt:
    cnt = cnt + 1.
END.

 
DO STOP-AFTER 5:
    RUN bumpCnt.
END.

* There might be circumstances in which the timer does not run, such as when the session is blocked waiting for a network message or a child process.

Workaround
Notes
References to Other Documentation:

OpenEdge® Development: ABL Reference ABL Syntax Reference: DO statement
Attachment 
Last Modified Date11/13/2015 9:52 PM


Feedback
 
Did this article resolve your question/issue?

   

Your feedback is appreciated.

Please tell us how we can make this article more useful. Please provide us a way to contact you, should we need clarification on the feedback provided or if you need further assistance.

Characters Remaining: 1025