Export (0) Print
Expand All

Slider.SelectionEnd Property

Gets or sets the largest value of a specified selection for a Slider.

Namespace: System.Windows.Controls
Assembly: PresentationFramework (in presentationframework.dll)
XML Namespace:  http://schemas.microsoft.com/winfx/2006/xaml/presentation

[BindableAttribute(true)] 
public double SelectionEnd { get; set; }
/** @property */
public double get_SelectionEnd ()

/** @property */
public void set_SelectionEnd (double value)

public function get SelectionEnd () : double

public function set SelectionEnd (value : double)

<object SelectionEnd="double" .../>

Property Value

The largest value of a selected range of values of a Slider. The default value is zero (0.0).

Identifier Field

SelectionEndProperty

Metadata properties set to true

BindsTwoWayByDefault

The value of the SelectionEnd property cannot be greater than the value of the Maximum property and cannot be less than the value of the Minimum property. The value of the SelectionEnd property must also be greater than or equal to the value of the SelectionStart property. If the value of the SelectionEnd property is greater than the value of the Maximum property or less than the value of the Minimum property, the value is set to the value of the Maximum or Minimum property respectively.

The following example shows how to set the SelectionEnd property. For the complete sample, see Slider Sample.

<Slider Width="100" Value="2" Orientation="Horizontal" HorizontalAlignment="Left" 
IsSnapToTickEnabled="True" Maximum="3" TickPlacement="BottomRight" 
AutoToolTipPlacement="BottomRight" AutoToolTipPrecision="2" 
Ticks="0, 1.1, 2.5, 3" IsSelectionRangeEnabled="true"
SelectionStart="1.1" SelectionEnd="3" Name="mySlider"/>

Slider hslider = new Slider();
hslider.Orientation = Orientation.Horizontal;
hslider.AutoToolTipPlacement =
  AutoToolTipPlacement.TopLeft;
hslider.AutoToolTipPrecision = 2;
hslider.IsDirectionReversed = true;
hslider.Width = 100;
hslider.IsMoveToPointEnabled = false;
hslider.SelectionStart = 1.1;
hslider.SelectionEnd = 3;
hslider.IsSelectionRangeEnabled = false;
hslider.IsSnapToTickEnabled = false;
hslider.TickFrequency = 3;
hslider.TickPlacement = TickPlacement.Both;
cv1.Children.Add(hslider);

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0

Community Additions

ADD
Show:
© 2014 Microsoft