End If

Verb: endIf

Terminates a command block started by If.




A student's average is stored in a variable. The If commanhd defines that if the value is greater than 7, a message appears on the screen stating that the student can participate in a draw. Then End If terminates the command block.

defVar --name studentAverage --type Numeric --value 8 --parameter
// Check the value of "studentAverage" and inform that you can participate in the draw, because this value is greater than 7.
if --left "${studentAverage}" --operator "Greater_Than" --right 7
	messageBox --title Grade --text "Congratulations! You can participate in the draw!" --icon "Information" --buttons "OK" --defaultbutton "FirstButton"
// At the end, the command block is closed.
logMessage --message "${studentAverage}" --type "Info"
// Display the value of "studentAverage" in the console.


A command block that starts with If always ends with End If. Hence, End If cannot be used without If.

See Also

  • Begin Do-While
  • Case
  • Continue
  • Else
  • Else If
  • End Case
  • End Do-While
  • End For Each
  • End While
  • Execute Subroutines
  • For
  • For Each
  • Go to
  • Go to If
  • If
  • Insert Label
  • Interrupt Loop
  • Next
  • Otherwise
  • Return from Subroutine
  • Run Subroutine
  • Run Subroutine If
  • Then
  • When
  • While