Re: Damn send button / Wind chill (nesting more efficient shock)
Re: Damn send button / Wind chill (nesting more efficient shock)
- Subject: Re: Damn send button / Wind chill (nesting more efficient shock)
- From: Jon Pugh <email@hidden>
- Date: Sun, 10 Mar 2002 23:19:35 -0800
At 9:45 PM +1100 3/4/02, Shane Stanley wrote:
>
I'll be glad when Jon gets back from his skiing trip.
I'm not. I was having more fun skiing and drinking. ;)
As for tell blocks, minimize them as much as possible. Nested tells are intentional, but as Ed says, nested application tells are more of an accident than an intent. Given the ability to nest tell blocks, you have to deal with nested application tells also.
I think the biggest problem is when a target gets messed up, but that doesn't happen if you explicitly state the application name in the script. When you try using variables for the tell blocks, then you can get addressing errors. Otherwise the tell block merely specifies the target of the Apple Events sent in that tell block. That means that the single line construct is no different from the multiple line construct.
Also, the Finder is faster than BBEdit at "handling" the "current date" scripting addition. I blame BBEdit's object resolution code, but that's just a guess. I replaced BBEdit with the Finder in Shane's script and got lots faster responses from the Finder.
I also found David Lloyd's comments to be sensible. He was commenting on the implicit application (your script editor) and how you might need to use a "fake" tell block (to an uninvolved app) to obscure your script editor's terminology so that you can access the scripting addition terminologies. He was talking about FaceSpan, but the same problem can occur in Script Debugger or HyperCard, which both are essentially scriptable script editors.
At 10:23 AM +0000 3/4/02, Mr Tea wrote:
>
Well, you've chucked the gauntlet down there, Shane. I ran a similar type of
>
test with a bunch of word processors and in the majority of cases the
>
embedded tell block was FASTER. I was so surprised that I thought I must be
>
addled from lack of sleep (or something) and retired to bed in confusion.
>
>
But I tested again after a refreshing night's rest, and found the same
>
thing.
You should go back to bed, as should I. ;)
It's impossible to say what's actually happening on your machine. You ought to post your scripts and see if others get the same results. It could be something specific to your machine or it could be some form of hereditary insanity.
Basically, only the inner tell affects the Apple Events that get sent. They should have no other affect, and it is likely that any effect being seen is caused by some other factors.
Jon
PS
I haven't even made it all the way through this thread, so I'll probably be slow in answering since I'm still wading through it all.
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.