F > FScrollBar.setScrollProperties |  |

FScrollBar.setScrollProperties

FScrollBar, FScrollBar.setScrollProperties, setScrollProperties

Availability

Flash Player 6.

Usage

    myScrollBar.setScrollProperties(pageSize, minPos, maxPos)

Parameters

`pageSize` An integer representing the number of positions displayed in the page view.

`minPos` An integer representing the minimum scrolled position.

`maxPos` An integer representing the maximum scrolled position.

Returns

Nothing.

Description

Method; specifies the `pageSize`, `minPos`, and `maxPos` properties of the scroll bar and sets the scroll bar's scroll box (thumb) to the proper size.

This method is for advanced users and programmers who create custom components; it cannot be used with scroll bars attached to text fields. When a scroll bar is attached to a text field, the scroll properties are automatically set according to the properties of the text field, and calling this method breaks the scroll bar for the text field.

Example

The following code sets the `pageSize`, `minPos`, and `maxPos` properties for a scroll bar attached to a custom list box component. The list box has 5 visible rows and a total of 20 items in the list. Given that the box is indexed from 0 to 19, the `maxPos` property is the total number of items in the box minus the number of items visible.

    scrollBar.setScrollProperties(5, 0, 15);

See also

`FScrollBar.setScrollPosition`