Re: string as key to record
Re: string as key to record
- Subject: Re: string as key to record
- From: Paul Berkowitz <email@hidden>
- Date: Thu, 19 Sep 2002 19:24:52 -0700
On 9/19/02 6:43 PM, "Malcolm Fitzgerald" <email@hidden> wrote:
>
John's script does not work if varVal is a string. The script sees an
>
unquoted string value, expects that to be a variable and complains
>
that the variable is undefined. Including the quotes in the
>
concatenation fixes it.
>
>
set varKey to "a"
>
set varVal to "3"
>
set varRecord to run script "
>
{" & varKey & ":" & "\"" & varVal & "\"" & "}"
>
return a of varRecord
>
Sounds good (unless it's real Unicode, as John said later). You've got a few
more concatenations than you need there:
set varKey to "a"
set varVal to "3"
set varRecord to run script "
{" & varKey & ":\"" & varVal & "\"}"
return a of varRecord
--
Paul Berkowitz
_______________________________________________
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.