Re: resetting record values to ""
Re: resetting record values to ""
- Subject: Re: resetting record values to ""
- From: John W Baxter <email@hidden>
- Date: Mon, 1 Jan 2001 20:56:34 -0800
Victor Yee <email@hidden> wrote
>
Hi Bryan,
>
>
Would this work for you?
>
>
property defaultRecord : {a:"", b:"", c:""}
>
>
set thisRecord to {a:"A", b:"B", c:"C"}
>
>
thisRecord -->{a:"A", b:"B", c:"C"}
>
>
set thisRecord to defaultRecord
>
>
thisRecord -->{a:"", b:"", c:""}
I think this is one of the places where I would prefer copy over set...
Same code except
--not this: set thisRecord to defaultRecord
copy defaultRecord to thisRecord
Doing it this way will preclude accidental changes to defaultRecord.
Michelle Steiner wrote:
>
BTW, it looks like you'll have to change the names of the "state" and
>
"month" fields because they are already used by Applescript.
Perhaps not...
copy {state:"a", month:"b"} to x
x's month
seems to work.
--John
--
John Baxter email@hidden Port Ludlow, WA, USA