P
PC
Trying to update some VBA I've developed to change a two dimensional array
to a custom data type as I've found it to be easier to work with the entire
array.
However, I ran into a problem when I tried to pass the array to a Listbox in
a userform.
With the array (Item) defined as a 2-d array the code
UserForm1.ListBox1.List = Item
works just fine and the array appears in the Userform.
However if I dim the "Item" array as a custom type I get the following error
"Only user-defined types defined in public object modules can be coerced to
or from a variant or passed to late-bound functions"
Is there something I can do to make this work?
TIA
PC
to a custom data type as I've found it to be easier to work with the entire
array.
However, I ran into a problem when I tried to pass the array to a Listbox in
a userform.
With the array (Item) defined as a 2-d array the code
UserForm1.ListBox1.List = Item
works just fine and the array appears in the Userform.
However if I dim the "Item" array as a custom type I get the following error
"Only user-defined types defined in public object modules can be coerced to
or from a variant or passed to late-bound functions"
Is there something I can do to make this work?
TIA
PC