get_scroll_position


int get_scroll_position(handle window,
                        int bar)

This function obtains the position of the slider in a scroll bar.

Parameters

handle window

The handle of the scroll bar or a handle of a standard window that contains a scroll bar. The interpretation placed upon this parameter depends upon the value specified for the next parameter.

int bar

scrollbar_identity::horizontal Identifies a standard horizontal scroll bar associated with a standard window. The parameter window is a handle of the standard window.
scrollbar_identity::vertical Identifies a standard vertical scroll bar associated with a standard window. The parameter window is a handle of the standard window.
scrollbar_identity::control Identifies a scroll bar whose handle is explicitly specified. The parameter window is a handle of the scroll bar control.

Return

int

Zero The call failed.
Other The position of the scroll bar.

Notes

This function and the functions

all support 32 bit positioning of the slider; whereas, the messages message::horizontal_scroll and message::vertical_scroll support only 16 bit positioning of the slider. These functions may be used to support 32 bit positions during the processing of the scroll bar messages; however, applications that require visual updates during tracking (notification scrollbar_notify::slider_track) may only support 16 bit values for the slider position.