:sign0085:
I have this code:
'-----------------------------------------------------
Sub Globals
Dim c(0)
Dim p(0)
End Sub
Sub bTest_Click
AddArrayList("al")
c() = GetControls("Main.Form1")
al.add(c())
Msgbox(c(0))
c() = GetControls("fTest")
al.add(c())
Msgbox(c(0))
p() = al.item(0)
Msgbox(p(0))
p() = al.item(1)
Msgbox(p(0))
End Sub
'-----------------------------------------------------
There are 2 problems:
1 - if i call this sub twice, the second time i get an error because
"al" is already instanced, there are a way to know it or i must put a
flag?
2 - I add to "al" 2 different arrays, but when i retrive the values with
p() = al.item(0) and p() = al.item(1) i get the same result. Why?
thanks
claudio
I have this code:
'-----------------------------------------------------
Sub Globals
Dim c(0)
Dim p(0)
End Sub
Sub bTest_Click
AddArrayList("al")
c() = GetControls("Main.Form1")
al.add(c())
Msgbox(c(0))
c() = GetControls("fTest")
al.add(c())
Msgbox(c(0))
p() = al.item(0)
Msgbox(p(0))
p() = al.item(1)
Msgbox(p(0))
End Sub
'-----------------------------------------------------
There are 2 problems:
1 - if i call this sub twice, the second time i get an error because
"al" is already instanced, there are a way to know it or i must put a
flag?
2 - I add to "al" 2 different arrays, but when i retrive the values with
p() = al.item(0) and p() = al.item(1) i get the same result. Why?
thanks
claudio