et scrollbar values to decimals -- 1/100's ths
jhurley at infostations.com
Wed Feb 2 08:56:06 CST 2005
>I set a scroll bar number format to "#.00" but I am unable to set the
>beginning and ending values to a decimal value.. Are we only allowed
>positive whole integers ? (That's what I seem to be limited to...)
Yes, only positive integers. But you can achieve the fractional
effect in the scroll bar handler. For example in a scroll bar with 0
and 100 as the start and end values:
on scrollbarDrag newThumbPosition
set numberformat to ".00"
put 100 - newThumbPosition into temp--or "put the endvalue of me -
put temp/100 into myValue
put myVlaue into field "myField"
This, in effect, reverses the start and end values, and puts a
decimal value into myField. There's no limit to the way in which you
can manipulate the value returned by the thumb position.
More information about the use-livecode