which procedure I write this code:
option1.value = true then
text1.enable = true
else
text1.enable = false

Recommended Answers

All 7 Replies

Click event of the option buttons


Good Luck

but when I click another option button then the textbox.enable not false

Option buttons = either one or the other NOT both. CheckBoxes = one, both, none.


Use the right control for the right application.

Good Luck

you mean it will possible with check box not with option button.

write this code in option1 click event (caption this option button as "Enable")

text1.enable=true


write this code in option2 click event (caption this option button as "Disable")

text1.enable=false

also set the default value for text1.enable at design time or in form load event

you mean it will possible with check box not with option button.

Yes

I saw it many project. vipin's solution is an way to do this.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.