Hi everyone,
Just wondering if it is possible to lock a range of buttons that have similar names when a main button is pressed in VBA, so that the user can not press these button after the main button is pressed. ...
Hi everyone,
Just wondering if it is possible to lock a range of buttons that have similar names when a main button is pressed in VBA, so that the user can not press these button after the main button is pressed. ...
Hi jake,
You've got to disable the buttons too:
(You may have to reverse the order - this code isn't tested)Please Login or Register to view this content.
If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)
You can't do one thing. XLAdept
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin
Thanks you this works, but is it possible to lock a number of buttons at the same time just by using one line of code, if the buttons all have similar names. for example I have a buttons called cmdSeat1 ranging to cmdSeat197, there are 197 in total. all with similar names, only difference being is the number within the name such as cmdSeat45 or cmdSeat67. Is it possible to lock them all at once using only one line of code.
You could use:
or something similar fr if Ctl.Name Like *Seat* etcPlease Login or Register to view this content.
I've solved it now but thanks for the help !!!
You're welcome!
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks