#ELSEIFDEF
Preprocessor conditional directive
Syntax:
#ifdef A
' Conditionally included statements if A is defined
#elseifdef B
' Conditionally included statements if A is not defined and B is defined
#else
' Conditionally included statements if both A and B are not defined
#endifDescription:
#elseifdef can be added to an #if block to provide an additional condition.
#elseifdef symbol is equivalent to #elseif defined (symbol)
#elseifdef symbol is equivalent to #elseif defined (symbol)
Examples:
#DEFINE B
#IFDEF A
Print "A is defined"
#ELSEIFDEF B
Print "A is not defined and B is defined"
#ELSE
Print "both A and B are not defined"
#ENDIF
#IFDEF A
Print "A is defined"
#ELSEIFDEF B
Print "A is not defined and B is defined"
#ELSE
Print "both A and B are not defined"
#ENDIF
- Since fbc 1.20.0
Differences from QB:
- New to Freebasic
See also:
Back to Preprocessor