473,386 Members | 1,842 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Group checkbox

Hi group,
How can I group a couple of check boxes on my form so that only ONE can be
checked an anytime?
I've tried placing them onto a panel but I can still check them both.

Using VB.NET
Regards

Jun 27 '08 #1
4 3980
You should use radio buttons for this type of behaviour as users will expect
to be able to check none, one or all checkboxes?

Otherwise, the only method I can think of is to put code in each
CheckedChanged event to uncheck all of the other checkboxes.

Kind regards

Rob

"axapta" <ja********@gmail.comwrote in message
news:78**********************************@microsof t.com...
Hi group,
How can I group a couple of check boxes on my form so that only ONE can be
checked an anytime?
I've tried placing them onto a panel but I can still check them both.

Using VB.NET
Regards
Jun 27 '08 #2
Thanks Rob.
And place the radio buttons on a panel? Sorry I'm not at work at the moment
and can't envisage how using radio buttons will work - surely they are
placed on the form one at a time like a check box?

"Rob Blackmore" <ro*@robblackmore.comwrote in message
news:81**********************************@microsof t.com...
You should use radio buttons for this type of behaviour as users will
expect to be able to check none, one or all checkboxes?

Otherwise, the only method I can think of is to put code in each
CheckedChanged event to uncheck all of the other checkboxes.

Kind regards

Rob

"axapta" <ja********@gmail.comwrote in message
news:78**********************************@microsof t.com...
>Hi group,
How can I group a couple of check boxes on my form so that only ONE can
be checked an anytime?
I've tried placing them onto a panel but I can still check them both.

Using VB.NET
Regards
Jun 27 '08 #3
Hi,

Yes - put each "set" of radio buttons in a different panel. Then you can
only select one from each set as the panel being the container control is
what determines that they are grouped together.

Kind regards

Rob
"axapta" <ja********@gmail.comwrote in message
news:16**********************************@microsof t.com...
Thanks Rob.
And place the radio buttons on a panel? Sorry I'm not at work at the
moment and can't envisage how using radio buttons will work - surely they
are placed on the form one at a time like a check box?

"Rob Blackmore" <ro*@robblackmore.comwrote in message
news:81**********************************@microsof t.com...
>You should use radio buttons for this type of behaviour as users will
expect to be able to check none, one or all checkboxes?

Otherwise, the only method I can think of is to put code in each
CheckedChanged event to uncheck all of the other checkboxes.

Kind regards

Rob

"axapta" <ja********@gmail.comwrote in message
news:78**********************************@microso ft.com...
>>Hi group,
How can I group a couple of check boxes on my form so that only ONE can
be checked an anytime?
I've tried placing them onto a panel but I can still check them both.

Using VB.NET
Regards
Jun 27 '08 #4
Thanks Rob, I'll give that a go.
"Rob Blackmore" <ro*@robblackmore.comwrote in message
news:F5**********************************@microsof t.com...
Hi,

Yes - put each "set" of radio buttons in a different panel. Then you can
only select one from each set as the panel being the container control is
what determines that they are grouped together.

Kind regards

Rob
"axapta" <ja********@gmail.comwrote in message
news:16**********************************@microsof t.com...
>Thanks Rob.
And place the radio buttons on a panel? Sorry I'm not at work at the
moment and can't envisage how using radio buttons will work - surely they
are placed on the form one at a time like a check box?

"Rob Blackmore" <ro*@robblackmore.comwrote in message
news:81**********************************@microso ft.com...
>>You should use radio buttons for this type of behaviour as users will
expect to be able to check none, one or all checkboxes?

Otherwise, the only method I can think of is to put code in each
CheckedChanged event to uncheck all of the other checkboxes.

Kind regards

Rob

"axapta" <ja********@gmail.comwrote in message
news:78**********************************@micros oft.com...
Hi group,
How can I group a couple of check boxes on my form so that only ONE can
be checked an anytime?
I've tried placing them onto a panel but I can still check them both.

Using VB.NET
Regards
Jun 27 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: luvdairish | last post by:
I tried posting a few times, but it hasn't shown up. Hope this one works. Problem: Having trouble hiding tables when page is loaded. Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0...
2
by: Jeff Robichaud | last post by:
Hi, This seems like a classic one (but I'm pretty new to Javascript)... I have a list of checkboxes for all the U.S. states and a checkbox "All" to check them all at once. The following...
1
by: kufre | last post by:
I need some help. I have a option group button that contain two checkbox call Active and Inactive on my Filing form. This is what I want, the Active box will alway be the default checkbox,the...
4
by: moondaddy | last post by:
There are different times when I will have a group of checkboxes and need to force only one to be checked at a time. I would also like to do this client side and not require a postback. These...
3
by: El | last post by:
I can get a total count for a whole option group field, but I need to be able to count each individual selection in an option group on a report. For example if I had a yes or no option...I would...
2
by: uoziod | last post by:
Hello. Sorry for my english :) I got a next problem. This is a HTML. <ul> <li id="cat3"><input type="checkbox" onChange="javascript:groupCatCheck('3', this)" name="categories" value="3"...
4
by: Richard Walker | last post by:
Hi I'm trying to disable/enable a group of checkboxes using javascript, but can't work out how to refer to them. eg: <form name="selectform" action="data.php" method="post"> <input...
1
by: inamul | last post by:
I want to select CheckBox based on data retrieved from mysql database table. Could anyone show me the simple way of doing it. Data store in table under colum "sectionOfInterest" is shown below...
3
by: vajra1987 | last post by:
Hello JS Group I have a few checkbox groups in my form . I would like to enable or disable them based on some values chosen in option boxes. I have the following code, the disableGroup function is...
3
by: student4lifer | last post by:
I thought the group check boxes would be parsed as an array, but the code below didn't print out as I expected. Could someone explain what I am missing? Thanks. ========== <html> <body>...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.