#elseif
Preprocessor conditional directive
#if (expression1)
Syntax
#if (expression1)
' Conditionally included statements if expression1 is True
#elseif (expression2)' Conditionally included statements if expression2 is True
#else' Conditionally included statements if both
' expression1 and expression2 are False
#endif' expression1 and expression2 are False
Description
Example
#define WORDSIZE 16
#if (WORDSIZE = 16)
' Do some some 16 bit stuff
#elseif (WORDSIZE = 32)
' Do some some 32 bit stuff
#else
#error WORDSIZE must be set To 16 Or 32
#endif
#if (WORDSIZE = 16)
' Do some some 16 bit stuff
#elseif (WORDSIZE = 32)
' Do some some 32 bit stuff
#else
#error WORDSIZE must be set To 16 Or 32
#endif
Differences from QB
- New to Freebasic
See also