Create a string in one cell based on checkbox selection

rizzo93

Active Member
Joined
Jan 22, 2015
Messages
301
Office Version
  1. 365
My spreadsheet has three checkboxes that users can select from. I want to create a string in one cell based on the checkboxes they select. I need to do this using a formula--no VBA.

If they select this:
1711720536212.png

Then the string I want should look like this:
SOC2;ISO​

Multiple values should be separated by semicolons but should not end with one.

I've tried using IF formulas with no success. Suggestions please?
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
Each of these assign into particular cell behind (like A1, B1, C1). Then in result cell You should be able to easy sort this out.
Like below with CHOOSE:

Excel Formula:
=CHOOSE($A$1+1,"","SOC2;")&CHOOSE($B$1+1,"","HITRUST;")&CHOOSE($C$1+1,"","ISO")
 
Last edited:
Upvote 0
Building off of kokosek's formula, this way you can select only 1 checkbox and not have a trailing ";".
Excel Formula:
=TEXTJOIN(";",,CHOOSE($A$2+1,"","SOC2"),CHOOSE($B$2+1,"","HITRUST"),CHOOSE($C$2+1,"","ISO"))
 
Upvote 1
Solution
It took me a little bit to figure out how it worked, but I finally got it! Thanks everyone!
 
Upvote 0
Looks like you could also use
Excel Formula:
=MID(IF(A2,";SOC2","")&IF(B2,";HITRUST","")&IF(C2,";ISO",""),2,16)
 
Upvote 0

Forum statistics

Threads
1,215,840
Messages
6,127,214
Members
449,369
Latest member
JayHo

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