1. Loading using Typed Data
Works -
#Constant CL = 0x0D
Current As Integer = 1
fileTest As String
fileTest = "test.dat"
Open To Write Current, fileTest
Write String Current, "Example" + Chr$(CL)
Close File Current
Dim Buffer(void)
Open To Read Current, fileTest
this As Integer
Repeat
Array Insert At Bottom Buffer(void)
this = Array Count(Buffer(void))
Read Byte 1, Buffer(this)
Until Buffer(this) = CL
Close File Current
CompiledString As String
For Index = 0 To Array Count(Buffer(void))
CompiledString = CompiledString + Chr$(Buffer(Index))
Next
Print CompiledString
Wait Key
Doesn't -
#Constant CL = 0x0D
Current As Integer = 1
fileTest As String
fileTest = "test.dat"
Open To Write Current, fileTest
Write String Current, "Example" + Chr$(CL)
Close File Current
Dim Buffer(void) As Byte
Open To Read Current, fileTest
this As Integer
Repeat
Array Insert At Bottom Buffer(void)
this = Array Count(Buffer(void))
Read Byte 1, Buffer(this)
Until Buffer(this) = CL
Close File Current
CompiledString As String
For Index = 0 To Array Count(Buffer(void))
CompiledString = CompiledString + Chr$(Buffer(Index))
Next
Print CompiledString
Wait Key
2. Multiple Creationg Issues
Global x, y, z As Float = 10.0
Print x, y, z
Wait Key