G
Guest
I have an application that requires a matrix of option buttons that changes
based on a table.
So far, I have a method of creating a collection that identifies each item,
but have not been able to make the item into an option button. Is this
possible?
For intX = 0 To intTotal
For intY = intX To intTotal
strX = Format(intX, "00")
strY = Format(intY, "00")
ctlArray(intX, intY) = "ctl" & strX & "_" & strY
colRadio.Add (ctlArray(intX, intY))
Next intY
Next intX
For Each newRadio In colRadio
newRadio.Left = Me.WindowLeft + 720
newRadio.Top = Me.WindowTop - 720
newRadio.ControlType = acOptionButton
Next
This code dies at the "For Each newradio in colRadio" with "Run-time error
'424': Object required.
Thanks in advance.
Woody
based on a table.
So far, I have a method of creating a collection that identifies each item,
but have not been able to make the item into an option button. Is this
possible?
For intX = 0 To intTotal
For intY = intX To intTotal
strX = Format(intX, "00")
strY = Format(intY, "00")
ctlArray(intX, intY) = "ctl" & strX & "_" & strY
colRadio.Add (ctlArray(intX, intY))
Next intY
Next intX
For Each newRadio In colRadio
newRadio.Left = Me.WindowLeft + 720
newRadio.Top = Me.WindowTop - 720
newRadio.ControlType = acOptionButton
Next
This code dies at the "For Each newradio in colRadio" with "Run-time error
'424': Object required.
Thanks in advance.
Woody