I just found out (the hard way) that if you have 2 lists and somewhere in your program you set
And later
... List A was empty
This was a bit unexpected
I overcame this with
Then later to restore
Is it supposed to maintain the equal relationship between the two lists if it is set to equal somewhere in the program, or is it a bug? - No other variables maintain this "automatic" equal relationship.
B4X:
ListB = ListA ' save old values for later retrieval
ListA.Clear
And later
B4X:
ListA = ListB ' Retrieve old values
This was a bit unexpected
I overcame this with
B4X:
ListB.Clear
For i = 0 to ListA.Size - 1
ListB.Add(ListA.Get(i))
Next
ListA.clear
Then later to restore
B4X:
ListA.Clear
For i = 0 to ListA.Size - 1
ListA.Add(ListB.Get(i))
Next
ListB.clear
Is it supposed to maintain the equal relationship between the two lists if it is set to equal somewhere in the program, or is it a bug? - No other variables maintain this "automatic" equal relationship.