Public Function basByteMask(BytIn As Byte, Mask As Byte) As Byte
'Michael Red 1/9/02
'As usual, for illustration ONLY.
'ByteIn is a BYTE (0-255)
'Mask is a BYTE (0-255)
'Returns a BYTE (0-255)
'Note: Values of BIts in the Byte:
' (Bit #8) = &H80 = 128 (MSB)
' (Bit #7) = &H40 = 64
' (Bit #6) = &H20 = 32
' (Bit #5) = &H10 = 16
' (Bit #4) = &H08 = 08
' (Bit #3) = &H04 = 04
' (Bit #2) = &H02 = 02
' (Bit #1) = &H01 = 01 (LSB)
' (Bit #7) = &H00 = 00 (Empty - Would ALWAYS Return 0)
basByteMask = BytIn And Mask
End Function