Skip to content

Min Property

Description

Gets or sets the minimum value for the slider.

Property Type

Read-write property

Syntax (Visual Basic)

Public Property Min() As Long

Remarks

Min is the minimum value for the slider.

The SliderPaneClick event is used to update the Value of the slider. The Value will need to be manually maintained each time the slider is clicked. A value from the XTPSliderCommand enumeration will be passed to the SliderPaneClick event, which specifies where the user clicked on the slider.

Slider Min/Max

Example

' Variable in global code section  
Dim ViewZoom As Long  

Private Sub StatusBar_SliderPaneClick(ByVal Pane As XtremeCommandBars.StatusBarSliderPane, ByVal Command As XtremeCommandBars.XTPSliderCommand, ByVal Pos As Long)  
    Dim nZoom As Long  
    nZoom = ViewZoom  

    Select Case Command  
        Case XTP_SB_LEFT: nZoom = 0  
        Case XTP_SB_RIGHT: nZoom = 200  
        Case XTP_SB_LINELEFT: nZoom = Max((Int(nZoom / 10) - 1) * 10, 0)  
        Case XTP_SB_LINERIGHT: nZoom = Min((Int(nZoom / 10) + 1) * 10, 200)  
        Case XTP_SB_THUMBTRACK: nZoom = Pos  
        Case XTP_SB_PAGELEFT: nZoom = Max(nZoom - 20, 0)  
        Case XTP_SB_PAGERIGHT: nZoom = Min(nZoom + 20, 200)  
    End Select  

    If (nZoom = ViewZoom) Then Exit Sub  

    ViewZoom = nZoom  
    Pane.Value = nZoom  
    StatusBar.FindPane(ID_INDICATOR_ZOOM).Text = nZoom & "%"  
End Sub

See Also


Copyright (c) 1998-2024 Codejock Technologies. All rights reserved.