Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Populating one cell using multiple checkboxes
Hi,
I've created a userform with a number of check boxes. I'm trying to get the text value of one or more checkboxes when selected returned to a single cell on my worksheet using a comma as the seperator between each value. Is it possible to have something on VBA to do that for me? Thanks. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Populating one cell using multiple checkboxes
Cells(1,1) = CheckBox1.Value & "," & CheckBox2.Value & "," & CheckBox3.Value
If this post helps click Yes --------------- Jacob Skaria "A#'s" wrote: Hi, I've created a userform with a number of check boxes. I'm trying to get the text value of one or more checkboxes when selected returned to a single cell on my worksheet using a comma as the seperator between each value. Is it possible to have something on VBA to do that for me? Thanks. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Populating one cell using multiple checkboxes
Thank you for your help but this didn't work the way i wanted. It returned
either "True" or "False" to the cell. I'm trying to get it to return the values of the checkboxes that are True only while ignoring the false. I thought i might need to use If ... Then statements. "Jacob Skaria" wrote: Cells(1,1) = CheckBox1.Value & "," & CheckBox2.Value & "," & CheckBox3.Value If this post helps click Yes --------------- Jacob Skaria "A#'s" wrote: Hi, I've created a userform with a number of check boxes. I'm trying to get the text value of one or more checkboxes when selected returned to a single cell on my worksheet using a comma as the seperator between each value. Is it possible to have something on VBA to do that for me? Thanks. |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Populating one cell using multiple checkboxes
You can try this.
I am assuming you have named the checkboxes with a prefix 'chk' Dim intTemp,strTemp For intTemp = 1 to UserForm1.Controls.count If Left(UserForm1.Controls(intTemp).name,3)= "chk" Then strTemp = strTemp & "," chkValue.value End If Next If this post helps click Yes --------------- Jacob Skaria "A#''''s" wrote: Thank you for your help but this didn't work the way i wanted. It returned either "True" or "False" to the cell. I'm trying to get it to return the values of the checkboxes that are True only while ignoring the false. I thought i might need to use If ... Then statements. "Jacob Skaria" wrote: Cells(1,1) = CheckBox1.Value & "," & CheckBox2.Value & "," & CheckBox3.Value If this post helps click Yes --------------- Jacob Skaria "A#'s" wrote: Hi, I've created a userform with a number of check boxes. I'm trying to get the text value of one or more checkboxes when selected returned to a single cell on my worksheet using a comma as the seperator between each value. Is it possible to have something on VBA to do that for me? Thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
adding multiple checkboxes in a single cell | New Users to Excel | |||
adding multiple checkboxes in a single cell | New Users to Excel | |||
Creating multiple checkboxes in a cell | Setting up and Configuration of Excel | |||
Checkboxes and multiple cell values | Excel Programming | |||
Populating a listbox will a certain cell on multiple worksheets in the activeworkbook | Excel Programming |