"Raymond E. Griffith" wrote:
> So I use the following script to filter out the extra zeros
>
> set numberformat to 0.##########
> repeat with i = 1 to 11
> put item i of
> "pmean,psumx,psumxsq,pstddev,ppopdev,pn,pminX,pQ1,pmed,pQ3,pmaxX" into
> thatprop
> put line i of the StatSymb of me && 0+the thatprop of me into line i of
> ans
> end repeat
> put ans into fld "Stats"
>
...
> I notice that for me, numberFormat always ignores the trailing #'s.
I'll take a wild stab at this. I just tried a straightforward script,
and numberformat acts as I'd expect, so I don't think that's the
problem. It looks to me like the values of your variables are being
converted when the values are pulled out of the custom properties. That
is, the numberformat is set when the script fills "pmean, psumx", etc.
with values.
In HyperCard, everything is stored as a string unless it becomes clear
that a number is needed. HyperCard will put the string values
"74.364,3718.2" etc. into the variables (preserving their lengths) and
won't convert the numberformat until the math is actually done (add 0 to
the value.)
In MetaCard (I'm guessing) pulling the value out of the custom property
and putting it into a variable is enough to force the numberformat
conversion. That would happen in the above script before the math is done.
If my theory is right, then you'd have to set the values of your
variables first, then set the numberformat, and then do the math.
--
Jacqueline Landman Gay | [EMAIL PROTECTED]
HyperActive Software | [EMAIL PROTECTED]
Custom hypermedia solutions | http://www.hyperactivesw.com
612.724.1596 | 612.724.1562 - fax
This is the MetaCard mailing list.
Archives: http://www.mail-archive.com/metacard%40lists.best.com/
Info: http://www.xworlds.com/metacard/mailinglist.htm