Re: Getting label from a record (part 2)
Re: Getting label from a record (part 2)
- Subject: Re: Getting label from a record (part 2)
- From: Nigel Garvey <email@hidden>
- Date: Wed, 19 Nov 2003 02:10:46 +0000
Arthur Knapp wrote on Tue, 18 Nov 2003 14:29:10 -0500:
>
> Subject: Re: Getting label from a record (part 2)
>
> Date: Tue, 18 Nov 2003 17:03:59 +0000
>
> From: Nigel Garvey <email@hidden>
>
>
Damn you, Nigel Garvey!!! ;-)
>
>
We both adopted a similiar approch, and yet you ended up producing a
>
solution 1,538,292 times more elegant than my own. Once again, I doth
>
my hat to you. :)
Oh come on, Arthur. That extra 289 is way too generous! :-)
After posting it, I tried it out on the properties of a message in
Emailer. (Digest #2167, to be precise.) It took about 12.5 seconds (!)
and returned the labels as chevroned class codes. By subtle means, I've
now reduced the time to just over 10.5 seconds but didn't know what to do
about the class codes until I studied your script. (Yours takes about
14.8 seconds on the same digest, but it does return Emailer's label
names.) The trick is to change:
>
> try
>
> r as real
>
> on error msg
... which works as required with an 'info for' record but not with an
Emailer property record, to:
try
kai of r
on error msg
... which works as required with both. (The text is a different colour in
Script Editor's result window too.) So 'kai of r' seems to be the way to
go, provided you can guarantee the script will never be used on a record
with a kai property.... :-)
NG
_______________________________________________
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.