f = freefile open f, "output.txt" write f, "This string is to be written to the file" close f