Re: "a reference to" failure
Re: "a reference to" failure
- Subject: Re: "a reference to" failure
- From: "Serge Belleudy-d'Espinose" <email@hidden>
- Date: Thu, 21 Jun 2001 03:06:38 +0200
At 13:51 -0400 20/06/01, Marc K. Myers wrote:
>
Is there a
>
reason why references like this will only work in top level or run
>
handler code?
>
>
--on makeGloss()
(
)
>
set wordList to sort (words of theText)
>
set wordRef to a reference to wordList
>
(* NEXT LINE CONTAINS THE REFERENCE THAT BREAKS *)
>
set glossList to {item 1 of wordRef}
We did talk about this a few days ago - upon my request. While the reasons are still somewhat unclear for me, someone suggested a workaround. Replace the offending lines like this:
script xObject
property wordList : {}
end xObject
set wordList's contents to sort (words of theText)
set wordRef to a reference to xObject's wordList
set glossList to {wordRef's item 1}
etc.
Serge
--
\\//\//\// Serge Belleudy-d'Espinose Institut Jacques Monod
// // //
http://www.ijm.jussieu.fr/ Univ. Jussieu - Paris
//\//\//\\