END IF

Top  Previous  Next

Action

End an IF .. THEN structure.

 

 

Syntax

END IF

 

 

Remarks

You must always end an IF .. THEN structure with an END IF statement.

 

You can nest IF ..THEN statements.

The use of ELSE is optional.

 

The editor converts ENDIF to End If when the reformat option is switched on.

 

See also

IF THEN , ELSE

 

 

Example

Dim Nmb As Byte

Again:                                   'label

Input " Number " , Nmb                   'ask for number

If Nmb = 10 Then                         'compare

Print " Number is 10"                 'yes

Else                                     'no

  If Nmb > 10 Then                     'is it greater

Print " Number > 10"                   'yes

  Else                                 'no

Print " Number < 10"                   'print this

  End If                               'end structure

End If                                   'end structure

End                                     'end program