BitSet – Set a bit in a number
‘ Set a bit in a value” NOTE: requires Power2()Function BitSet(ByVal value As Long, ByVal bit As Long) As Long ‘ simply OR with the bit mask ‘ Range checking
‘ Set a bit in a value” NOTE: requires Power2()Function BitSet(ByVal value As Long, ByVal bit As Long) As Long ‘ simply OR with the bit mask ‘ Range checking
‘ Clear a bit in a value” NOTE: requires Power2()Function BitClear(ByVal value As Long, ByVal bit As Long) As Long ‘ simply AND with the negation of the bit mask
‘ Shift to the left of the specified number of times” NOTE: requires Power2()Function ShiftLeft(ByVal value As Long, ByVal times As Long) As Long ‘ we need to create a
‘ Rotate an Integer to the left the specified number of times” NOTE: requires Power2()Function RotateLeftI(ByVal value As Integer, ByVal times As Long) As Integer Dim i As Long, signBits
‘ Rotate an Integer to the right the specified number of times” NOTE: requires Power2()Function RotateRightI(ByVal value As Integer, ByVal times As Long) As Integer Dim i As Long, signBits
When you write a screen saver in C and SDK you can use a static library (SCRNSAVE.LIB) that allows you to create custom dialogs to change and request the password.
‘ Test the value of a bit” NOTE: requires Power2()Function BitTest(ByVal value As Long, ByVal bit As Long) As Boolean ‘ simply AND with the bit mask ‘ Range checking
‘ Toggle a bit in a value” NOTE: requires Power2()Function BitToggle(ByVal value As Long, ByVal bit As Long) As Long ‘ simply XOR with the negation of the bit mask
‘ Rotate a Long to the left the specified number of times” NOTE: requires Power2()Function RotateLeft(ByVal value As Long, ByVal times As Long) As Long Dim i As Long, signBits