Output option buttons as text to new sheet

johnselekta

New Member
Joined
Jun 14, 2011
Messages
6
Hi guys

I have an array of option buttons in a group (named Agegrp, located on Sheet1). When an option is selected, I have this linking to a second sheet recording the data (cell = D3, worksheet = datacollection).

Currently, my 6 options are coming out numbered 1-6 instead of their respective age ranges. How can I make this record the label entry not the button number?

1 = <30
2 = 31-40
3 = 41-50
4 = 51-60
5 = 61-70
6 = >70

Got a seriously hard time on my hands today, so any help is a big help! Thanks ;)
 
Last edited:

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
Cheers for that, never heard of VLOOKUP, looks easy enough! Got another couple of questions, will make them in a new thread. :)
 
Upvote 0
Right then the plot thickens! I found I can just use this to read one value

=IF(datacollection!D3=1,"<30")

So how would I chain this to 6 different numbers instead of just a single entity? I'm new to all this but can code a bit, so am still getting my head round the syntax :help:
 
Last edited:
Upvote 0
If you want to avoid having a lookup table try

=CHOOSE(Results!D3,"<30","31-40","41-50","51-60","61:70",">70")
 
Upvote 0
Ah brill I just worked out a solution but I'm gonna use yours!

I had

=IF(datacollection!D3=1,"<30",IF(datacollection!D3=2,"31-40")) etc etc

But yours seems to be much slicker! THANK YOU so much.:)

EDIT: it is indeed an awesomely simple solution, I salute you!
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,583
Messages
6,179,681
Members
452,937
Latest member
Bhg1984

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top