Re: Check if file exists fails
Re: Check if file exists fails
- Subject: Re: Check if file exists fails
- From: Bernhard Waldbrunner <email@hidden>
- Date: Mon, 7 Jan 2008 00:56:45 +0100
On Sun, 06 Jan 2008, Axel Luttgens wrote:
Hello Bernhard,
You just met what makes the ASLG so nice: each word counts... ;-)
On page 129, Table 4-1 ("Standard application-only commands") indeed
lists command "exists"; moreover, that same table specifies "exists"
as
a "commonly supported" command.
Translation: AppleScript itself isn't able to execute command
"exists",
but an application _may_ provide such a command and know how to
perform it.
So, as Matthew already noted, the Finder is such an application.
And so is System Events.
More generally, the "exists" command is described as determining
"whether the object speciï¬ed by a reference exists" (p. 139).
This thus means that even if an application provides an "exists"
command, this is not necessarily for checking the existence of files
(or
folders, or disks...); for example, it could be provided by a word
processor for checking whether the third paragraph exists.
HTH,
Axel
Thank you Axel for explaining that. Also, thanks Matthew, wrapped in a
tell block it works. I must have overlooked this line in the sample
script.
Bernhard _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden