'Activity module
Sub Process_Globals
End Sub
Sub Globals
End Sub
Sub Activity_Create(FirstTime As Boolean)
Dim MyMap As Map
Dim MyArray(2) As String
Dim fileMap As RandomAccessFile
MyMap.Initialize
MyArray(0)="1"
MyArray(1)="0"
Log("* Charge")
For number = 0 To 3
MyMap.Put(number, MyArray)
Log(MyArray(0) & "-" & MyArray(1))
Next
Log("* Load Directly")
For number = 0 To 3
MyArray = MyMap.Get(number)
Log(MyArray(0) & "-" & MyArray(1))
Next
Log("* Write file")
'File.WriteMap(File.DirRootExternal ,"MyMap_deleteme.txt", MyMap)
fileMap.Initialize(File.DirRootExternal ,"MyMap_deleteme.txt", False)
fileMap.WriteObject(MyMap,False, number)
fileMap.Close
Log("* Read file")
MyMap.Clear
fileMap.Initialize(File.DirRootExternal ,"MyMap_deleteme.txt", True)
MyMap = fileMap.ReadObject(number)
fileMap.Close
For number = 0 To 3
MyArray = MyMap.Get(number) '<--------- I'M FAILED!!!!
Log(MyArray(0) & "-" & MyArray(1))
Next
End Sub