where does a "put file" go?

Klaus Major klaus at major-k.de
Tue Mar 7 17:25:02 EST 2006


Hi Ben,

> If I do the following in a script, where does it go?
> put fld "data field" into url "file:test data.txt"

it goes into the current directory.

You can check it with a little script like:
...
put the directory
...

That will return the folder where you can find your file.

> How can I open the file to read it, independently of Rev?

Just doubleclick that file and Textedit (on a Mac) or Editor
(on windows) will start and open it.

Of course you can manage where to save that file, e.g. with
"specialfolderpath(xyz)" or something.

This will save the file on your desktop:
...
put fld "data field" into url ("file:" & specialfolderpath("desktop")  
& "/test data.txt")
...

> Thanks,
>
> Ben

Regards

Klaus Major
klaus at major-k.de
http://www.major-k.de




More information about the Use-livecode mailing list