Re: Script Menu in 10.6.2
Re: Script Menu in 10.6.2
- Subject: Re: Script Menu in 10.6.2
- From: Deivy Marck Petrescu <email@hidden>
- Date: Thu, 4 Feb 2010 12:52:26 -0500
On Feb 3, 2010, at 5:19 PM, Shane Stanley wrote:
> On 4/2/10 9:02 AM, "Luther Fuller" <email@hidden> wrote:
>
>> It seems that using ...
>>
>> tell application "Finder" to (path to ...)
>>
>> will poison the remainder of the script, at least when the script is run from
>> the Scripts menu.
>> But, why?
>
> It's possible the Finder is getting confused by the new scripting addition
> security behavior (it doesn't take much...).
>
> "path to" is a scripting addition command, so it should be put outside an
> app tell block if possible (the exception is commands that generate
> dialogs).
>
> People should get used to writing things like:
>
> set docFolder to path to documents folder
> tell application "Finder"
> set ListOfFiles to name of files of docFolder
> end tell
>
> The 10.6 release notes cover this issue.
>
> --
> Shane Stanley <email@hidden>
> AppleScript Pro, April 2010, Florida <http://www.applescriptpro.com>
Shane,
I fell this is a bug.
Your statement "The 10.6 release notes cover this issue." would be correct if the behavior was consistent across the board.
It turns out that if you run the script in ASE or as an app it works as expected (or not!) and if run from SM then it behaves differently.
In my dictionary, I call this a bug.
If you run it as an app in SM then it also runs correctly.
If the op does not report it I will.
Deivy Petrescu
email@hidden
_______________________________________________
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