round and statRound

David Burgun dburgun at dsl.pipex.com
Wed Apr 13 15:45:54 EDT 2005


yeah, I solved it with:

if  Value is not an integer then
put truc(Value + 1) into value
end if

Cheers
Dave

>What about?
>
>put ceil(25.0) = 26, not the indended result.
>
>Try:
>
>function ceil pVal
>   if pVal mod trunc(pVal) = 0 then return pVal
>   return trunc(pVal)+1
>end function
>
>
>-Chipp
>
>Alex Tweedly wrote:
>>Alex Tweedly wrote:
>>
>>>Don't think there's one built-in.
>>>
>>>function ceil pVal
>>>  return ceil(pVal)+1
>>>end ceil
>>>
>>Sorry - I meant
>>    return trunc(pVal)+1
>>
>
>_______________________________________________
>use-revolution mailing list
>use-revolution at lists.runrev.com
>http://lists.runrev.com/mailman/listinfo/use-revolution



More information about the use-livecode mailing list