Public Class Form1

 

    Private Sub TrackBar1_Scroll(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TrackBar1.Scroll

        Label1.Text = "The slider value is: " & TrackBar1.Value

    End Sub

 

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        TrackBar1.Minimum = 1

        TrackBar1.Maximum = 1000

        TrackBar1.TickFrequency = 50

        TrackBar1.SmallChange = 50

        TrackBar1.LargeChange = 100

    End Sub

 

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        Me.Close()

    End Sub

End Class