Re: Converting Associative List to Record
Re: Converting Associative List to Record
- Subject: Re: Converting Associative List to Record
- From: Deivy Petrescu <email@hidden>
- Date: Thu, 6 Nov 2003 19:32:39 -0500
On Nov 6, 2003, at 7:28 AM, Frank wrote:
As a new Applescript user I was wondering if there is an easy way to
create records from associative list:
For example to convert the list
{"name", "Frank", "city", "Brussels"}
to
{name: "frank", city: "Brussels"}
Best Regards,
Frank
Here is the *best* solution:
set lista to {"name", "Frank", "city", "Brussels"}
to usrf(theList)
script
{+class usrf;:theList}
end script
run script the result
end usrf
set usrfList to usrf(lista)
_______________________
Unfortunately it is not mine! It is Olof Hellman's.
But hey, go ahead and use it, he will not complain.
Regards
Deivy
http://www.dicas.com/
_______________________________________________
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.