|
-
Jun 22nd, 2007, 11:59 AM
#1
Thread Starter
PowerPoster
[RESOLVED] Radio buttons not working right???
I have a VB.Net 2005 application in which I have a form that contains 2 sets of Radio buttons (2 Radio Buttons per set). A screenshot of the form is attached.
The values of these RDO's are "Yes" and "No" for each set. Each RDO is named separately. For the 1st set, I click either "Yes" or "No", however, when I click on the 2nd set...the value for the 1st set is removed. The object is that both sets contain either a "Yes" or "No" value. I set the values in the Click Event of each control. What am I doing wrong?
Thanks,
-
Jun 22nd, 2007, 12:14 PM
#2
Re: Radio buttons not working right???
you need to put each set into a different container, like a Group Box or a panel...
-tg
-
Jun 22nd, 2007, 12:15 PM
#3
Re: Radio buttons not working right???
Place each group of radio buttons in it's own container, like a GroupBox, or a panel.
EDIT: Dammit TG, I'm just too slow.
-
Jun 22nd, 2007, 12:34 PM
#4
Thread Starter
PowerPoster
Re: Radio buttons not working right???
I'll give it a shot but why does it have to work that way? Just curious!
-
Jun 22nd, 2007, 12:40 PM
#5
Re: Radio buttons not working right???
Because option buttons in the same container are considered to be a set, regardless of how many or how few there are. The only way to separate them is to use different containers. They were designed that way.
-
Jun 22nd, 2007, 12:54 PM
#6
Thread Starter
PowerPoster
Re: Radio buttons not working right???
Ok,
I did that. Now, when I select one from each container, in that RDO's Click Event, I check the .Checked Property. If it's been selected, I assign a value to a variable, but for some reason the value isn't passed back to a grid (which contains a complete record). It was passing back a value before but now that it's in a container, it's not doing it.
-
Jun 22nd, 2007, 01:32 PM
#7
Re: Radio buttons not working right???
Double check the event handler.... make sure the Handles.... is still there... if not, add it back in... when you cut controls off of a form (which I assume you did to get them onto the container)... it removes the handles clause, but doesn't put it back when you paste them back.
-tg
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
|