• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
(no subject)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

(no subject)


  • Subject: (no subject)
  • From: Oakley Masten <email@hidden>
  • Date: Wed, 15 Apr 2009 09:18:04 -0700 (PDT)

On Date: Wed, 15 Apr 2009 09:51:53 +0200
Alexis Gottlieb <email@hidden>  Wrote
On Subject: Re: Copy to list Question


Hi,

You can handle dictionaries (ie, associative arrays whose keys are  
strings) by using the plist commands of the free scripting addition  
XMLLib.osax (from Satimage-software):

set p to PlistNew
PlistSet p key "var1" to "Cat"
PlistSet p key "var2" to "Dog"
PlistSet p key "var3" to "Horse"
PlistSet p key "var4" to "Bird"

set ListAnimals to {}
repeat with x from 1 to 4
    copy (PlistGet p key ("var" & x)) to end of ListAnimals
end repeat
ListAnimals

--or:
set ListAnimals to PlistGet p key (PlistGetKeys p)

PlistClose p--free memory: p is not valid any more


XMLLib.osax is available at: http://www.satimage.fr/software/en/downloads/downloads_companion_osaxen.html

Best regards,
Alexis

Alexis 

I have downloaded the OSAX and am trying to run the plist tutorial
Small problem:  My computer - MacBookPro Intel - 10.4.11 does not have the requested plist 
"AddressBookMe.plist"

It has "com.apple.AddressBook.plist" but that doesn't appear to be the correct item.

any Thoughts?

Thanks
Oakley 

 _______________________________________________
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

  • Prev by Date: re: Copy to List Question
  • Next by Date: Re: Copy to List Question
  • Previous by thread: Re: Copy to list Question
  • Next by thread: Info for
  • Index(es):
    • Date
    • Thread