Re: New to AppleScript,please help.
Re: New to AppleScript,please help.
- Subject: Re: New to AppleScript,please help.
- From: Deivy Petrescu <email@hidden>
- Date: Sat, 08 Jan 2011 10:22:08 -0500
On Jan 8, 2011, at 09:11 , KOENIG Yvan wrote:
>
> Le 8 janv. 2011 à 14:52, Deivy Petrescu a écrit :
>>
>>
>> set l to "/Users/deivy/Desktop/reaching.txt"
>> try
>> tell application "System Events" to open l
>> on error e
>> return e
>> end try
>>
>> -- Events---
>> tell application "System Events"
>> open "/Users/deivy/Desktop/reaching.txt"
>> --> missing value
>> --> error number 0
>> end tell
>> Result:
>> missing value
>>
>> the error message on the screen
>>
>> <Screen shot 2011-01-08 at 08.47.30 .png>
>>
>>
>>
>> System Events dictionary says it needs an alias...
>
> I bet that this one will run flawlessly :
>
> set l to "/Users/deivy/Desktop/reaching.txt"
> try
> tell application "System Events" to open disk item l
> on error e
> return e
> end try
>
> Yvan KOENIG (VALLAURIS, France) samedi 8 janvier 2011 15:10:56
You would lose the bet...
In this case the dialog that came up with my example does not show up.
set l to "/Users/deivy/Desktop/reaching.txt"
try
tell application "System Events" to open disk item l
on error e
return e
end try
--Events--
tell application "System Events"
open disk item "/Users/deivy/Desktop/reaching.txt"
--> error number 0
end tell
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