Occurs when the scroll box on a ScrollBar control, or an object which contains a scrollbar, is repositioned or scrolled horizontally or vertically.
Private Sub object_Scroll( )
The parts of the Scroll event syntax are described in the following table.
Part | Description |
---|---|
object | An object expression that evaluates to an object. |
For a ComboBox control, this event occurs only when the scrollbars in the dropdown portion of the control are manipulated.
You can use this event to perform calculations or to manipulate controls that must be coordinated with ongoing changes in scroll bars. In contrast, use the Change event when you want an update to occur only once, after a ScrollBar control changes.
Note Avoid using a MsgBox statement or function in this event.