'Declaration Public Event BeforeScroll As BeforeScrollEventHandler
public event BeforeScrollEventHandler BeforeScroll
The event handler receives an argument of type BeforeScrollEventArgs containing data related to this event. The following BeforeScrollEventArgs properties provide information specific to this event.
Property | Description |
---|---|
Cancel (Inherited from System.ComponentModel.CancelEventArgs) | |
OwnerScroll | Returns whether the scroll action applies to owner scrolling. |
ScrollAction | Returns the scroll action that was taken |
The BeforeScroll event is a cancelable event. If the event is canceled, the AfterScroll event does not fire, and the control is not scrolled.
Private Sub UltraMonthViewSingle1_BeforeScroll(ByVal sender As System.Object, ByVal e As Infragistics.Win.UltraWinSchedule.BeforeScrollEventArgs) Handles ultraMonthViewSingle.BeforeScroll '---------------------------------------------------------------------------------------------------- ' Description ' BeforeScroll ' ' Fires before the control is scrolled. ' If the BeforeScroll event is canceled, the control is not scrolled, and the AfterScroll event does not fire. ' '---------------------------------------------------------------------------------------------------- If e.ScrollAction = ScrollEventType.ThumbTrack Then e.Cancel = True End Sub
private void ultraMonthViewSingle1_BeforeScroll(object sender, Infragistics.Win.UltraWinSchedule.BeforeScrollEventArgs e) { //---------------------------------------------------------------------------------------------------- // Description // BeforeScroll // // Fires before the control is scrolled. // If the BeforeScroll event is canceled, the control is not scrolled, and the AfterScroll event does not fire. // //---------------------------------------------------------------------------------------------------- if ( e.ScrollAction == ScrollEventType.ThumbTrack ) e.Cancel = true; }
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2