hello all.
i'm want to add a new element in existing structure but a can't...
i'm try this code
but it doesnot work correct...
i'm want to add a new element in existing structure but a can't...
i'm try this code
B4X:
Sub Globals
Dim Type(s1,s2)var(0)
Dim Type(s1,s2)var2(0)
End Sub
Sub App_Start
var()=Array((1,2),(2,3))
Dim var2(ArrayLen(var()),ArrayLen(var(),2))
var2()=var()
'ArrayCopy(var(),0,ArrayLen(var()),var2(),0)
Dim var(ArrayLen(var2())+1,ArrayLen(var(),2))
ArrayCopy(var2(),0,ArrayLen(var2()),var(),0)
'var()=var2()
var(ArrayLen(var())-1).s1=3
var(ArrayLen(var())-1).s2=4
For i=0 To ArrayLen(var())-1
s=s&var(i).s1
Next
Msgbox(ArrayLen(var()),s)
End Sub