Share via


ValidatingSelectorValue<T>.SelectedIndex Property

Definition

Gets or sets the index of the currently selected item or returns negative one (-1) if the selection is empty.

public:
 property int SelectedIndex { int get(); void set(int value); };
public:
 property int SelectedIndex { int get(); void set(int value); };
public int SelectedIndex { get; set; }
member this.SelectedIndex : int with get, set
Public Property SelectedIndex As Integer

Property Value

Remarks

If you set SelectedIndex to a value less that -1, an ArgumentException is thrown. If you set SelectedIndex to a value equal or greater than the number of child elements, the value is ignored.

Applies to