exporting text file?

by Nick (no login)

 

is is possible to export/read a text file (or any other type of file) so that you can (for ex.) save a game i was hopeing to do something like this


num1 = 10
num2 = 22
num3 = 52
name$ = YOUR

'some magical line(s) of code that would save a file (name$).txt
'to a specified location on the hard Drive
'starting here:

PRINT "Hello, " name$;" 's numbers are:"

PRINT " "

PRINT num1, num2, num3

' END of file, and saved code here...


and end up with a YOUR.txt file on the HDD that when opens sais:


Hello, YOUR's numbers are:

102252



p.s. I know the code i given won't really work, i just forget at the top of my head the proper way to PRINT variables....


any thoughts/suggestions?
thxs!

Posted on Aug 6, 2009, 11:45 AM

Respond to this message   

Goto Forum Home

Response TitleAuthor and Date
* use 'OPEN "foo.txt" for OUTPUT AS #1' and PRINT #1, "foo"Anon on Aug 6
You can create a WRITE # file.Clippy on Aug 6

 Copyright © 1999-2017 Network54. All rights reserved.   Terms of Use   Privacy Statement  

Quantcast