|
-
Nov 30th, 2005, 03:48 PM
#1
Thread Starter
Hyperactive Member
Public Sub not working
I have a series of option buttons on a worksheet. I would like to run them through a routine when a value is changed...but it is not working....help?
VB Code:
Sub ColorMe (opt as OptionButton)
If opt.value = True then
opt.caption= "chosen"
Else
opt.caption = "not"
End if
Private Sub optNumber1_Change()
ColorMe optNumber1
End Sub
Talk does not cook rice.
-Chinese Proverb
-
Nov 30th, 2005, 03:49 PM
#2
Re: Public Sub not working
Step thru the code and check the value of the option button. I don't know if true and false are correct. In VB6, there is VBChecked, VBUnchecked, and VBGreyed
-
Nov 30th, 2005, 03:54 PM
#3
Thread Starter
Hyperactive Member
Re: Public Sub not working
good point, but, actually it is not even getting that far,
I am getting a type mismatch, or object error, when it gets to the
ColorMe optNumber1
statement...
I have tried numerous different ways....and still no luck
Talk does not cook rice.
-Chinese Proverb
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|