Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Lists, Arrays, or Records ????



Hello Everyone

If I run this script

tell application "iCal"
	
	set the_cals to the {name, description} of every calendar
	
end tell
 (forget the "missing value" issue with iCal Calendar Descritpions.

I get A list containing two lists one of "names" and one of "descriptions". I think of this as array like.

Name1
Name2
Name3

followed by

Description1
Description2
Description3

I think I would like something that looks more like a "record". Or in other words can I get the result back as a List containing a List for each calendar the second list would contain the name and description.

Name1, Description1
Name2, Description2
Name3, Description3

So my question is two fold.

1. Can I get back a more "record" like structure with a different syntax? I know I could roll my own handler to do this, but I was just wondering if there was "as Record" syntax that I don't know about.

2. If I am interested in the speed of looping through these lists, does it matter which form I use? Should I just stick to the first method?

Thanks

Todd


--

Todd Geist
______________________________________
g e i s t   i n t e r a c t i v e

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-users/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.