EdwardMartinIII
Technical User
I have a spreadsheet in Excel 2007.
Each row is a condition, but at the end of each condition is a button that reads "not applicable."
If I press that button, then I want every (specified cell value) to switch to 0, and every (specified control) to change its attributes a certain way.
These things are not, however, necessarily consecutive.
It doesn't matter what order they're executed.
So, a sort of pseudo-code would be:
The reason for doing this is to reduce fiddling with code for each row by only fiddling with the Group declarations.
Thanks!
Edward ![[monkey] [monkey] [monkey]](/data/assets/smilies/monkey.gif)
"Cut a hole in the door. Hang a flap. Criminy, why didn't I think of this earlier?!" -- inventor of the cat door
Each row is a condition, but at the end of each condition is a button that reads "not applicable."
If I press that button, then I want every (specified cell value) to switch to 0, and every (specified control) to change its attributes a certain way.
These things are not, however, necessarily consecutive.
It doesn't matter what order they're executed.
So, a sort of pseudo-code would be:
Code:
set GroupOfCells = {d18, e18, g18}
set GroupOfControls = {Button108, Button109, Button110}
set TargetCell as range
set TargetControl as control (?)
{upon "Applicable" button being pressed...}
for each TargetCell in GroupOfCells
TargetCell.value = 0
next
for each TargetControl in GroupOfControls
TargetControl.caption = "banana"
TargetControl.color = red
TargetControl.enabled = false
next
The reason for doing this is to reduce fiddling with code for each row by only fiddling with the Group declarations.
Thanks!
![[monkey] [monkey] [monkey]](/data/assets/smilies/monkey.gif)
![[monkey] [monkey] [monkey]](/data/assets/smilies/monkey.gif)
"Cut a hole in the door. Hang a flap. Criminy, why didn't I think of this earlier?!" -- inventor of the cat door