Thanks, Paul. I've incorporated the "if name of every process contains" code
and have my applet working again, but the mystery remains...


on 4/05/01 2:32 PM, Paul Berkowitz at [EMAIL PROTECTED] wrote:
> On 4/5/01 10:33 AM, I wrote:
> 
>> First reports on MacScrpt, from people using AS 1.4.3 (OS 9.0.4) and AS
>> 1.1 (OS 7.5.5) show that 'running' just compiles as an undefined variable
>> and errors as such when run, even in a Finder tell block.
>> 
>> On the other hand, there are two Scripting Additions: "Is Application
>> Running 1.0.0" and "RunningApps 1.0", which have the term 'running'?
>> Do/did you have one of those installed?
>> 
>> Now I'm beginning to suspect that 'running' is a new term in the Finder
>> for AS 1.6, and is actually there for the new Script Runner in OS X, where
>> it will have a different meaning.


I do not have either of those scripting additions, never heard of them.

I swear, that code I posted compiled, executed, and worked as I wanted it to
(returning true when an application was running) under 9.1 and AS 1.5.5.

Consistent with what you describe below, under AS 1.6 the code compiles and
executes with "running" as a valid keyword, albeit not with the same meaning
as before, never returning true. If moved out of the tell Finder block, it
errors with "running" as an undefined variable.

 
> Nope. It turns out that in 1.6 (and 1.5.5 as well, I believe: OS 9.1), there
> is a new application property:
> 
>   execution state -- starting up/running/rebuilding
> desktop/copying/restarting/quitting [r/o] -- the current execution state of
> the Finder
> 
> 
> That's where 'running' is defined. Since 'running' is something that only
> refers to the application property 'execution state', it only gives 'true'
> there but will compile anywhere in a Finder tell block, and give false as a
> result for any other Finder property.  (you can try the sane sort of thing
> within Entourage with a misplaced application keyword:
> 
> if account of message 1 of in box folder is high then
>   set x to true
> else
>   set x to false
> end if
> --  false
> 
> 'high' belongs only to 'priority', not to account'. But _don't_ try this
> with 'leave on server': that returns 'true'! (It's a bug.)
> 
> So that's how 'running' should now behave in a Finder tell block. It does
> now supercede any osax term 'running' within a Finder tell block, just as
> (annoyingly) Entourage's 'file' term supercedes AppleScript's file term, let
> alone any osax, within an Entourage block.
> 
> So you can still use 'running' as you're accustomed to _outside_ a Finder
> block if you still have the osax installed, as I showed in the last email,
> or use the 'process' script I first gave you _inside_ a Finder block,
> whichever you prefer.


-- 
To unsubscribe:               <mailto:[EMAIL PROTECTED]>
To search the archives: 
          <http://www.mail-archive.com/entourage-talk%40lists.boingo.com/>

Reply via email to