Let's say we have 12 combo boxes on a form (I actually have 40, but for this example let's keep it small). Those combo boxes are broken into 4 groups of 3. I'm trying to figure out the VBA code that would in essence create a range out of each group. This would be so that later I could make loop statements to check out / compare the values of each combobox against it's own group.
I am currently having to write verrrrry long If / Then statements like;
Code:
If cbo1 = cbo2 And cbo2 = cbo3 Then
(answer)
ElseIf cbo1 <> cbo2 And cbo2 = cbo3 Then
(answer)
ElseIf........
Well, you should hopefully get the picture of all the combinations to test through, and the above is just for one group!
Once someone has helped with that conundrum (or I happen to figure it out), the next logical question from me would be how to setup the testing statement? In other words, how do I have cbo1 check it's value against the other two cbo's, and so forth?
Thanks for any pointers in the right direction.