Select All Radio Button

Lochwood

Registered User.
Local time
Today, 12:37
Joined
Jun 7, 2017
Messages
130
Hi,

I have created a form with a selection of radio buttons the user clicks on to show results in a query. The buttons are not tied to a group and can have multiple selections. My question is, how do i create a select all radio button that can turn all radio buttons on without the user having to manually click every button. i have 4 columns of radio buttons with about 10 in each column and am thinking a select all radio button at the top of each column. Can this be done?
 
try the onclick or afterupdate of the select all radio button

me.option1 = me.OptionAll
me.option2 = me.optionAll
etc,

this should set them true or false depending on the what the All button is.
obviously change the above to match your button names.
 
rename all radio button with uniformity, ie:

radio1, radio2, radio3, radio4, ....

then you can just create a For Next loop:

Code:
Dim i As Integer
For i = 1 To x (number of radio from the above radio button names)
	Me.Controls("radio" & i) = True
Next
 
try the onclick or afterupdate of the select all radio button

me.option1 = me.OptionAll
me.option2 = me.optionAll
etc,

this should set them true or false depending on the what the All button is.
obviously change the above to match your button names.

moke123 this worked a treat.. thanks
 

Users who are viewing this thread

Back
Top Bottom