Re: name extension
Re: name extension
- Subject: Re: name extension
- From: kai <email@hidden>
- Date: Wed, 4 May 2005 23:28:16 +0100
On Wednesday, May 4, 2005, at 10:42 pm, Michelle Steiner wrote:
If foo doesn't have a name extension,
Tell application "Finder" to get name extension of foo
--> ""
name extension of (info for foo)
--> missing value
How come the difference?
Good question.
For this job I used 'info for', rather than Finder, because it proved
to be generally faster. However, the speed advantage is dented by that
ghastly check for a missing value - which also makes the script longer
than it would otherwise need to be. On top of that, the line looks
downright ugly (IMO). ;-)
I now see that Nigel suggested a similar approach before I did. (Mail
didn't group his reply with the others from the same thread, so I
missed it first time around.) His version is much prettier, of course.
;-)
---
kai
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden