*--Create a new file lnFileHandle = FCREATE ('myfile.txt') *--write text to the file FWRITE (lnFileHandle, 'This is the text I want to write') FWRITE (lnFileHandle, Chr(13)) && with fwrite() you need to send a carriage return if you want it FWRITE (lnFileHandle, 'This is more text') FWRITE (lnFileHandle, Chr(13)) *--close the file handle (otherwise it will remain locked and inaccessible FCLOSE (lnFileHandle)