Help With DataBuffer
Monkey Forums/Monkey Programming/Help With DataBuffer| 
 | ||
| I looked in many Topics in this forum and I can't make DataBuffer to load it is returning NULL. In the example below I can make the LoadString work, so it is not a path issue. I am using MonkeyXPro84e (Mojo 2) 
Import mojo
Import brl.databuffer
	Method OnCreate:Int()
		Local stream = DataBuffer.Load("data/test.bin")
                Local inData:= stream.ReadInt()
                If Not stream Then
			Print("Missing data file!")
		End
                Local memory:String = LoadString("data/test.bin")
		Print "File size=" + memory.Length() + " bytes"
		
		If Not memory Then
			Print("Missing data file!")
		End
		'Print "Memory Length:" + memory.Length()
		Return 0
	End
 |