Within excel I have developed a chunk of code the cyclically changes the selected command button background color every time the button is pressed.
This code has been used on around 50 buttons and works well.
The worksheet contains other chunks of code and has a reset feature (button) which returns the sheet to a default preferred state.
The challenge is to programmatically change the 50 or so command button colors back to a known state when the reset is pressed - being a newbie at this am struggling for a solution - my initial thoughts are to use a for next to loop through the command buttons and set the background properties.. Something like....
For ValBut= 1 To 50
CommandButton & ValBut.BackColor = &HE0E0E0
Next ValBut
Obviously this does not work...
Help Please!!
This code has been used on around 50 buttons and works well.
The worksheet contains other chunks of code and has a reset feature (button) which returns the sheet to a default preferred state.
The challenge is to programmatically change the 50 or so command button colors back to a known state when the reset is pressed - being a newbie at this am struggling for a solution - my initial thoughts are to use a for next to loop through the command buttons and set the background properties.. Something like....
For ValBut= 1 To 50
CommandButton & ValBut.BackColor = &HE0E0E0
Next ValBut
Obviously this does not work...
Help Please!!