Try OpenEdge Now
skip to main content
ABL Reference
ABL Syntax Reference : NOT operator (bitwise)
 

NOT operator (bitwise)

Performs a bitwise NOT operation on a flag enum instance and returns an instance of the same type.

Syntax

NOT flag-enum-expression
flag-enum-expression
An expression whose value is a flag enum instance. The expression cannot be the Unknown value (?).

Example

You can use bitwise NOT to turn off a flag. This code fragment defines a variable of type Progres.Reflect.Flags (see the Progress.Reflect.Flags enumeration entry for a full list of enumerators) and uses NOT to make sure the Static flag is not set while leaving the other flags unchanged.
DEFINE VARIABLE flagsEnum AS Progress.Reflect.Flags.

flagsEnum = flagsEnum AND NOT Flags:Static.

Notes

*This operator can be used with both ABL and .NET flag enums.

See also

AND operator (bitwise), ENUM statement, OR operator (bitwise), XOR operator (bitwise)