//********************************************************************************
//
// Saving a data file
//
//********************************************************************************
// This will fail if the file exists!!! so delete it first if it does
open to write 1,"data.dat"
message$="Hello world"
score=9999
write string 1,message$ : ` this saves a string
write string 1,str$(score) : ` this saves an integer as a string
// remember to close files when you have finished!!
close file 1
//********************************************************************************
//
// Loading a data file
//
//********************************************************************************
open to read 1,"data.dat"
read string 1,message$ : ` reads a string from the file
read string 1,temp$ : ` reads string into a temp value
score=val(temp$) : ` then converts temp$ to integer
close file 1
This is one way of do it using DBP native commands.