F
Fred Flintstone
I have an app that requires the use of a 2 dimensional array of
checkboxes. I can't seem to assign any values to them. I tried this:
Dim BonusChecks(0, 0) As CheckBox
...and then later when I know the domensions I'll need:
ReDim BonusChecks(x,y) ' (3,3), no error
BonusChecks(0,0).ID = "1" 'Object reference not set to an instance of
an object
If it's not allocated any memory, what did the redim statement do?
So I found another syntax:
Dim BonusChecks(3,3) as New Checkbox ' No error
BonusChecks(0,0).ID = "1" ' Same error,
What am I missing? I thought ReDim or New would initialize the array.
How do I get an array of checkboxes working?
Thanks!
checkboxes. I can't seem to assign any values to them. I tried this:
Dim BonusChecks(0, 0) As CheckBox
...and then later when I know the domensions I'll need:
ReDim BonusChecks(x,y) ' (3,3), no error
BonusChecks(0,0).ID = "1" 'Object reference not set to an instance of
an object
If it's not allocated any memory, what did the redim statement do?
So I found another syntax:
Dim BonusChecks(3,3) as New Checkbox ' No error
BonusChecks(0,0).ID = "1" ' Same error,
What am I missing? I thought ReDim or New would initialize the array.
How do I get an array of checkboxes working?
Thanks!