exists(file on my computer) not doing very well
Klaus major-k
klaus at major-k.de
Mon Sep 1 16:46:39 EDT 2014
Hi Richmond,
Am 01.09.2014 um 21:21 schrieb Richmond <richmondmathewson at gmail.com>:
> In a card of my upcoming "Grendel" for Anglo-Saxon, Gothic and other warped
> Germanic languages/writing-systems I have this script:
>
> on preOpenCard
> set the title of stack "grendel" to the short name of this card
> ## if exists(url("file:" & "GrendelBackUp.rtf")) then
not sure about the syntax for EXISTS and FILE, but -> url("file:"...) is surely not the way to go!
Why not just use: if there is a file xyz...?
> put "exists"
> set the RTFText of fld "store" to URL ("file:" & "GrendelBackUp.rtf")
> else
> put "nope"
> end if
> end preOpenCard
>
> Now the file GrendelBackUp.rtf is present where I saved it earlier, from the stack,
> in the default folder.
>
> So would be glad if somebody could tell me why I keep getting "nope" in my Message Box.
See above!
> Richmond.
Best
Klaus
--
Klaus Major
http://www.major-k.de
klaus at major-k.de
More information about the use-livecode
mailing list