11-12-2023, 07:02 AM
(11-12-2023, 06:54 AM)TerryRitchie Wrote: If you need bits (presumably as flags) you could always use a _BYTE and manipulate each of the 8 bits. This will give you 8 flags to choose from.Yes, an _Byte would work.
Code: (Select All)TYPE BitStruct
xbits AS _BYTE
END TYPE
DIM BitsStructure AS BitStruct
BitsStructure.xbits = BitsStructure.xbits XOR 8 ' toggle 4th bit
PRINT BitsStructure.xbits
BitsStructure.xbits = BitsStructure.xbits XOR 8 ' toggle 4th bit
PRINT BitsStructure.xbits