From QB64 Wiki
$END IF is precompiler command, which determines which sections of code inside its blocks are included into our code for compiling.
- $IF variable = expression THEN...
- .$ELSEIF variable = expression THEN...
- $END IF
- $END IF denotes the end of a valid precompiler $IF block.