106 of 286
92 GetBit Type Function returning Byte Invocation GetBit(var, bitNumber) Parameter Method Type Description var ByRef any type The variable from which the bit will be read. bitNumber ByVal int8/16 The bit number to read. Discussion This function extracts a single bit from memory beginning at the location of the specified variable. Bit numbers 0-7 are taken from the byte at the specified location, bit numbers 8-15 are taken from the subsequent byte, etc. In each case, the lower bit number corresponds to the least significant bit of the byte while the higher bit number corresponds to the most significant bit. The return value will always be 0 or 1. Compatibility In BasicX compatibility mode the second parameter must be a Byte type. See Also PutBit