Click to See Complete Forum and Search --> : Bit manipulation


anita_vs
July 12th, 2001, 09:45 PM
My form consists of a toolbar which has 10buttons and 3 command buttons.All the buttons are disabled on the form load.When i click on the command button1 the second and third buttons of the toolbar gets activated.Here i want to set bits for those activated buttons.

For ex:

0000000000 --start condition
0110000000 --after one command activates
0001111000 -- after clicking 2nd command button.

I hv declared 2 constants
const br= &H68E7780 hex equivalent of 0110000000

const cr=10F3D8 hex equivalent of 0001111000.

On command 3 ,i'll be checking as :

if my_toolbarstatus=br then
// statements
elseif my_toolbarstatus=cr then
//statements
else
statements
endif

Any help in this regard is appreciated.

Anita

cksiow
July 12th, 2001, 11:00 PM
seems like you don't have to make the problem so complicated, just check the .Enable property of each button will let you know which button has been click.


HTH

cksiow
http://vblib.virtualave.net - share our codes

anita_vs
July 13th, 2001, 12:09 AM
hi cksiow

They are ways to do it, but our requirement is in this way.

Anita