Re: R e: Coerce string to record or something like that?
Re: R e: Coerce string to record or something like that?
- Subject: Re: R e: Coerce string to record or something like that?
- From: JJ <email@hidden>
- Date: Thu, 13 Dec 2001 20:45:03 +0100
>
> set entry_1 to record {+class usrf;:{"status", "unproc"}}
>
>
Hmm... nope. That simply gave me a -10008 error ("The specified object is a
>
property, not an element."). If only it were that simple.:) I suspect you
>
must have additional coercions installed if it's working for you.
OK.
Unistalled every helper osaxen, INIT, appe & cdev's.
Restart.
Running 8.6, AppleScript 1.3.7
set entry_1 to record {<<class usrf>>:{"status","unproc"}}
Within script editors:
Smile > error -10008
Scripter > error msg "can't obtain record ..."
Script Editor > no problems
Script Debugger > no problems
Mini Script Editor > no problems
Try this running from an applet. It should work for you.
set entry_1 to record {+class usrf;:{"status", "unproc"}}
set This_Works to status of entry_1
display dialog This_Works
It must be a problem of "Smile", since I don't wish compile, i.e.,
execute window "Test"
as far as "execute" isn't an osax command (at least in my machine) and isn't
enclosed into a "tell" block.
Seems that "the specified object is a property" makes reference to
{<<class usrf>>:... (So, "record" would be interpreted as an event, not a
descriptor, and is expecting any reference to "record"). I don't know.
Supposse these are internal features of the program itself, not AppleScript.
Also, try this code, (posted to me by Michael). It should work, too, within
both Smile & Scripter.
set The_Record to {{<<class usrf>>:{"status", "unproc"}}} as string as
record
Greetings & happy scripting!
JJ