Hi Erel,
I do not know English and use the Google translator . I have a big problem. I have to make an application that works with binary files. Must work with binary files because the files are also managed by Windows applications written in VB6 .
In VB6 type is declared like this:
Type Classification
Name As String * 15
Points As Integer
Goal As Integer
end Type
and then there is an array like this:
Public Cla ( 1 To 20 ) As Classification
This array is saved in a binary file with a for next:
For i = 1 To 20
Put # 1 , Cla ( i)
Next i
and when it should be read:
For i = 1 To 20
Get # 5 , Cla ( i)
Next i
I tried to do it in B4A but I can not make it work:
Type Classification ( Name As String , Value As Short , goal As Short )
but when I write I do not know what to do. I tried with:
Dim a As Classification
a.initialize
a.name ="Juventus"
a.points=22
a.goal=19
raf.Initialize ( File.DirRootExternal , " Class.gsc " , False)
raf.WriteObject (a, False , raf.CurrentPosition )
Please if you can help me. Maybe show me a tutorial on the RAF.