Looking good:
[CODE lang="b4x" highlight="5-36"]Sub Button1_Click
'''xui.MsgboxAsync("Hello world!", "B4X")
Dim bc As ByteConverter
File.Copy(File.DirAssets, "Points1.bin", File.DirInternal, "Points1.bin")
Dim raf As RandomAccessFile
raf.Initialize(File.DirInternal, "Points1.bin", True)
Dim b(8) As Byte
raf.ReadBytes(b, 0, b.Length, raf.CurrentPosition)
Dim NumPoints As Int = bc.LongsFromBytes(b)(0)
Log(NumPoints)
Dim PointNumber As Int = 0
Do While True
Dim b(12) As Byte
Dim Result As Int = raf.ReadBytes(b, 0, b.Length, raf.CurrentPosition)
If Result < 12 Then Exit
PointNumber = PointNumber + 1
If PointNumber < 6 Or PointNumber > NumPoints - 6 Then
Dim fff() As Float = bc.FloatsFromBytes(b)
Dim xf As String = NumberFormat2(fff(0), 1, 5, 5, False)
Dim yf As String = NumberFormat2(fff(1), 1, 5, 5, False)
Dim zf As String = NumberFormat2(fff(2), 1, 5, 5, False)
Log(PointNumber & TAB & xf & TAB & yf & TAB & zf)
End If
Loop
End Sub[/CODE]
[CODE lang="html" title="Log Output"]Logger connected to: HMD Global Nokia C01 Plus
--------- beginning of system
--------- beginning of main
100000
1 -53932.60156 -145979.79688 27.76000
2 -53932.39844 -145979.79688 27.76000
3 -53932.19922 -145979.79688 27.76000
4 -53932.00000 -145979.79688 27.76000
5 -53931.80078 -145979.79688 27.76000
99995 -54153.00000 -145968.20312 18.60000
99996 -54152.80078 -145968.20312 18.60000
99997 -54152.60156 -145968.20312 18.60000
99998 -54152.39844 -145968.20312 18.59000
99999 -54152.19922 -145968.20312 18.59000
100000 -54152.00000 -145968.20312 18.58000
100001 -54151.80078 -145968.20312 18.58000[/CODE]