From the wonderful RedGuides Wiki

This command is added by MacroQuest

Syntax Key
Notation Description
Text without brackets or braces Required items
<Text inside angle brackets> Placeholder for which you must supply a value
[Text inside square brackets] Optional items
Vertical bar (|) Separator for mutually exclusive items; choose one
{Text | inside | braces} Set of required items; choose one
Ellipsis () Items that can be repeated
Syntax /next <varname>
Description This runs all commands between the /for line and the /next line, after which it increments/decrements the varname number by step number (default is 1) before running through the commands again. It will keep doing this until the varname number equals the to or downto number. You can end a /for loop immediately with /break or try the next iteration with /continue.



See the Command:/for page for examples

See also