how to execute a macro assigned to a checkbox in vba
Dave,
thanks for your help, i managed to achieve what i wanted to do with
your help.
for future reference:
now that i worked out how to do it i can also explain better what i
want to do:-)
i want to execute a macro assigned to a checkbox in vba, while in the
code all i have is the name of the checkbox, my final code looks like
this:
dim myCBX as checkbox
dim checkBoxAction as String
Set myCBX = seriesWorkbook.ActiveSheet.CheckBoxes( checkBoxName)
checkBoxAction = myCBX.OnAction
If "" < checkBoxAction Then
Run checkBoxAction
End If
before i had allready tried:
Run myCBX.OnAction
in analogy to a button control, but that doesn't work.
thanks again for your help,
Pieter
|