Handler behaving oddly
Scott Morrow
scott at elementarysoftware.com
Wed Jul 19 05:13:19 EDT 2006
Ian,
Hmm... It worked fine on my end.
-Scott Morrow
On Jul 19, 2006, at 1:36 AM, Ian McKnight wrote:
> Hi
>
> The handler below is designed to check that a value is within a
> certain range.
> If it is outside the range it displays the word ERROR and stops
> otherwise it displays the first 10 characters in the value.
>
> The handler behaves oddly.
>
>
> Thanks
>
> Ian McKnight
>
> ===============================================
>
> function checksize theAns
> -- check if too big or too small
> if (theAns > 10^8 -1) or (theAns < 10^(-8))
> then
> put "Error" into fld "Display"
> exit to top
> else
> set the numberformat to "0.########" -- maximum 8 places of
> decimals
> return (char 1 to 10 of theAns ) -- show 10 sig figs truncated
> end if
> end checksize
>
> ===============================================
More information about the use-livecode
mailing list