Here are some issues:
- The array data1 has never been dimensioned so you can't assign anything to it. Also in your assignment you can't use empty parentheses.
- You have declared your variables but you have allowed them all to default to Variant. It is a better practice to declare them as specific data types.
- Your argument to Evaluate is a bit confusing because you are using two nested Transpose functions. That just transposes them once and then transposes them back to where you started.
- If multiple checkboxes are checked then you are copying data into the same array over and over again. If you are requiring that only one of them can be checked, then I recommend using option buttons instead of checkboxes.
You want this. Declaring data1 as a Variant instead of a Variant array allows the dimensions to be set automatically when you do the assignment. After this assignment you can treat data1 as though it had been declared as an array with dimensions (1 To 1, 1 To 6). You don't need any of that Transpose jazz.
Bookmarks