I am trying to write an array (Dim kKur(100) As kkSquare) of Type kkSquare (y As Int, x As Int, Tipe As Int, Waarde As Int, Index As Int) to a file to being able to restore the values when the application restart. In the Activity_Pause I have used the following:
File.WriteList (File.DirRootExternal, "SudStkKur.txt", kKur)
and in my Activity_Resume i have:
kKur = File.Readlist (File.DirRootExternal, "SudStkKur.txt")
but without any success. I gets an error telling me one is of type kkSquare and the the other is a list. If I change the read to Listkk as List on the left hand side, I can "see" my values under debug with the types of kkSquare. My question is how can I address these values,
1. something like Listkk(i).Tipe?
2. do I have to write kKur line for line and read it the same way?
3. can I give assign Listkk back to the array kKur?
File.WriteList (File.DirRootExternal, "SudStkKur.txt", kKur)
and in my Activity_Resume i have:
kKur = File.Readlist (File.DirRootExternal, "SudStkKur.txt")
but without any success. I gets an error telling me one is of type kkSquare and the the other is a list. If I change the read to Listkk as List on the left hand side, I can "see" my values under debug with the types of kkSquare. My question is how can I address these values,
1. something like Listkk(i).Tipe?
2. do I have to write kKur line for line and read it the same way?
3. can I give assign Listkk back to the array kKur?