I have code that finds all unique values in a range.
I am currently trying to create a checkbox on a form for each unique value with the name of the checkbox same as the value.
So, I can't figure out exactly how to use VBA to add a checkbox. Also, is something like this possible:
If I can make a dynamic array based on the number of unique values found (x), then Id be one more step closer to doing what I need, but I still can't figure out how to create the checkbox.
I realize now this is a 2-part question...
Part 1, How do I make a checkbox on a form usa VBA?
Part 2, How do I create a dynamic array?
Thanks for looking and for any help you can provide.
I am currently trying to create a checkbox on a form for each unique value with the name of the checkbox same as the value.
So, I can't figure out exactly how to use VBA to add a checkbox. Also, is something like this possible:
Code:
Dim x as Integer
Dim checkboxes(x)
x = 10
with checkbox(1)
'bla bla bla'
end with
with checkbox(2)
'bla bla'
end with
If I can make a dynamic array based on the number of unique values found (x), then Id be one more step closer to doing what I need, but I still can't figure out how to create the checkbox.
I realize now this is a 2-part question...
Part 1, How do I make a checkbox on a form usa VBA?
Part 2, How do I create a dynamic array?
Thanks for looking and for any help you can provide.