G
Guest
I have a problem assigning a control with index to an object type variable with SE
no problem at all when the control isn't a member of an arra
obviously, because of my application purpose, can't refeer explicity to the objec
Objects in Form1
- Option1(0
- Option1(1
- Option
Dim WithEvents MyOption As VB.OptionButto
Private Sub Command1_Click(
Dim lobj1 As Object, lobj2 As VB.OptionButto
For Each lobj1 In Form1.Control
'change "Option2" for "Option1" and it will raise an Error 45
If lobj1.Name = "Option2" The
Set MyOption = lobj
End I
Nex
End Su
Private Sub MyOption_Click(
MsgBox "OK
End Su
Any sugestions? thnx a lot!
no problem at all when the control isn't a member of an arra
obviously, because of my application purpose, can't refeer explicity to the objec
Objects in Form1
- Option1(0
- Option1(1
- Option
Dim WithEvents MyOption As VB.OptionButto
Private Sub Command1_Click(
Dim lobj1 As Object, lobj2 As VB.OptionButto
For Each lobj1 In Form1.Control
'change "Option2" for "Option1" and it will raise an Error 45
If lobj1.Name = "Option2" The
Set MyOption = lobj
End I
Nex
End Su
Private Sub MyOption_Click(
MsgBox "OK
End Su
Any sugestions? thnx a lot!