Orientation in WPF Range Slider (SfRangeSlider)

The Orientation property has the following two options.

  1. Horizontal
  2. Vertical

The default option is Horizontal.

<editors:SfRangeSlider
                    Width="300"
                    Maximum="100"
                    Minimum="0"
                    Orientation="Horizontal"
                    Value="50" />
Grid parentGrid = new Grid();
            SfRangeSlider rangeSlider = new SfRangeSlider()
            {
                Width = 300,
                Maximum = 100,
                Minimum = 0,
                Value = 50,
                Orientation = Orientation.Horizontal
            };

            parentGrid.Children.Add(rangeSlider);
            this.Content = parentGrid;;

Horizontal

The following code sample illustrates how to set vertical orientation to SfRangeSlider.

<editors:SfRangeSlider
                    Height="300"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Maximum="100"
                    Minimum="0"
                    Orientation="Vertical"
                    Value="50" />
Grid parentGrid = new Grid();
            SfRangeSlider rangeSlider = new SfRangeSlider()
            {
                Width = 300,
                Maximum = 100,
                Minimum = 0,
                Value = 50,
                Orientation = Orientation.Vertical
            };

            parentGrid.Children.Add(rangeSlider);
            this.Content = parentGrid;;

Vertical