File input/output reading and writing to and from disc
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
File input/output reading and writing to and from disc
Quoted by Simon: Here is the lesson for a simple text file:
http://lessons.runrev.com/s/lessons/m/4 ... put-output
Read with interest this post. Just so that I understand things correctly, does this particular tutorial deal with, by way of a practical example, say I had a huge data file culled from the internet that lists all RGB, L*A*B and CMYK values for a given colour space; I could include this file as a part of the application (stored independently on a user's hard drive) and the actual stack I code would refer to this file? in as much as the user would insert a single line or integer and then receive a result. Is this what all this is about? Does this deal only with static data files and not with data files that are updated constantly within the global network (ie the news)?
Thankyou
chris
http://lessons.runrev.com/s/lessons/m/4 ... put-output
Read with interest this post. Just so that I understand things correctly, does this particular tutorial deal with, by way of a practical example, say I had a huge data file culled from the internet that lists all RGB, L*A*B and CMYK values for a given colour space; I could include this file as a part of the application (stored independently on a user's hard drive) and the actual stack I code would refer to this file? in as much as the user would insert a single line or integer and then receive a result. Is this what all this is about? Does this deal only with static data files and not with data files that are updated constantly within the global network (ie the news)?
Thankyou
chris
Re: File input/output reading and writing to and from disc
Could you please provide the COMPLETE link to the tutorial? Thanks!
Re: File input/output reading and writing to and from disc
Hi Chris,
Since I am a lazy guy, I got used to the URL syntax with file handling.
Instead of:
open file ...
write "THis is text" to file...
or
read from file...
close file...
I use the one-liner to write to disk:
...
put "This is text" into url("file:" & specialfolderpath("documents") & "/a_text_file.txt")
...
Resp. to get a file from disk:
...
put url("file:" & specialfolderpath("documents") & "/a_text_file.txt") into fld "test text file"
...
The tutorial is about writing/reading data (of whatever kind!) to/from the users harddisk.
Best
Klaus
ah, thanks!chris25 wrote:Quoted by Simon: Here is the lesson for a simple text file:
http://lessons.runrev.com/s/lessons/m/4 ... put-output
Since I am a lazy guy, I got used to the URL syntax with file handling.
Instead of:
open file ...
write "THis is text" to file...
or
read from file...
close file...
I use the one-liner to write to disk:
...
put "This is text" into url("file:" & specialfolderpath("documents") & "/a_text_file.txt")
...
Resp. to get a file from disk:
...
put url("file:" & specialfolderpath("documents") & "/a_text_file.txt") into fld "test text file"
...
Sorry, I don't have the slightest idea what you meanchris25 wrote:Read with interest this post. Just so that I understand things correctly, does this particular tutorial deal with, by way of a practical example, say I had a huge data file culled from the internet that lists all RGB, L*A*B and CMYK values for a given colour space; I could include this file as a part of the application (stored independently on a user's hard drive) and the actual stack I code would refer to this file? in as much as the user would insert a single line or integer and then receive a result. Is this what all this is about? Does this deal only with static data files and not with data files that are updated constantly within the global network (ie the news)?

The tutorial is about writing/reading data (of whatever kind!) to/from the users harddisk.
Best
Klaus
Re: File input/output reading and writing to and from disc
Hi Chris,
Klaus's way is the way I use reading and writing to a file. I just couldn't find a lesson on that method.
Simon
Klaus's way is the way I use reading and writing to a file. I just couldn't find a lesson on that method.
Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!
Re: File input/output reading and writing to and from disc
Sorry guys I thought this was something else.