Skip to content

End

See Also: Begin, If

Purpose

To establish the "bottom" of a Begin … End block.

Syntax

BeginEnd

What It Does

The End command marks the point in a program at which execution resumes in the event the block is not executed (skipped).

Example

If (Found) 
Begin
    Lock
    Move (Irritant.Counter + 1) To Irritant.Counter
    Save Irritant
    Unlock
End

Notes

  • If an End command is provided with no preceding Begin, For, Repeat, or While command, the compiler will report an error.

  • You may place Begin ... End blocks inside other Begin ... End blocks up to a limit of 40. You may freely intermingle them with other block control commands (loops). However, you may not overlap them — you must end the innermost block first, then the next-innermost, and so on.