New to Telerik UI for ASP.NET AJAX? Start a free 30-day trial

Represents a collection of DropDownListItem objects within the RadDropDownList control.

Definition

Namespace:Telerik.Web.UI

Assembly:Telerik.Web.UI.dll

Syntax:

C#
public class DropDownListItemCollection : ControlItemCollection, IList, ICollection, IStateManager, IList<DropDownListItem>, ICollection<DropDownListItem>, IEnumerable<DropDownListItem>, IEnumerable

Inheritance: objectStateManagedCollectionControlItemCollectionDropDownListItemCollection

Implements: ICollectionICollection<DropDownListItem>IEnumerableIEnumerable<DropDownListItem>IListIList<DropDownListItem>IStateManager...

Inherited Members ControlItemCollection.VisibleChildren<T>()ControlItemCollection.Add(ControlItem)ControlItemCollection.Contains(ControlItem)ControlItemCollection.CopyTo(ControlItem[], int)ControlItemCollection.AddRange(IEnumerable<ControlItem>)ControlItemCollection.IndexOf(ControlItem)ControlItemCollection.Insert(int, ControlItem)ControlItemCollection.Remove(ControlItem)ControlItemCollection.FindChild<TControlItem>(Predicate<TControlItem>)ControlItemCollection.FindChildByText<TControlItem>(string)ControlItemCollection.FindChildByValue<TControlItem>(string)ControlItemCollection.FindChildByAttribute<TControlItem>(string, string)ControlItemCollection.FindChildByValue<TControlItem>(string, bool)ControlItemCollection.FindChildByText<TControlItem>(string, bool)ControlItemCollection.AddItemToParentControls(int, ControlItem)ControlItemCollection.OnInsertComplete(int, object)ControlItemCollection.OnRemoveComplete(int, object)ControlItemCollection.OnClear()ControlItemCollection.SetDirtyObject(object)ControlItemCollection.ParentControlItemCollection.VisibleItemsControlItemCollection.ListStateManagedCollection.Clear()StateManagedCollection.CopyTo(Array, int)StateManagedCollection.CreateKnownType(int)StateManagedCollection.GetEnumerator()StateManagedCollection.GetKnownTypes()StateManagedCollection.OnClearComplete()StateManagedCollection.OnValidate(object)StateManagedCollection.OnInsert(int, object)StateManagedCollection.OnRemove(int, object)StateManagedCollection.SetDirty()StateManagedCollection.Countobject.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()object.GetType()object.MemberwiseClone()...

Constructors

C#
public DropDownListItemCollection(Control parent)
Parameters:parentControl

Properties

Gets or sets the DropDownListItem at the specified index.

C#
public DropDownListItem this[int index] { get; set; }
Parameters:indexint

Implements: IList<DropDownListItem>.this[int]

Methods

Appends an item to the collection.

C#
public void Add(DropDownListItem item)
Parameters:itemDropDownListItem

The item to add to the collection.

Implements: ICollection<DropDownListItem>.Add(DropDownListItem)

Appends an item to the collection.

C#
public virtual void Add(string text)
Parameters:textstring

The text of the new item.

Inserts an item to the collection at the specified index.

C#
public void Insert(int index, DropDownListItem item)
Parameters:indexint

The zero-based index at which item should be inserted.

itemDropDownListItem

The item to insert into the collection.

Inserts an item to the collection at the specified index.

C#
public virtual void Insert(int index, string text)
Parameters:indexint

The zero-based index location at which to insert the DropDownListItem.

textstring

The text of the new item.

Removes the specified item from the collection.

C#
public void Remove(DropDownListItem item)
Parameters:itemDropDownListItem

The item to remove from the collection.

Removes the DropDownListItem object at the specified index from the current DropDownListItemCollection.

C#
public void RemoveAt(int index)
Parameters:indexint

The zero-based index of the item to remove.

C#
protected override void SetOwner(ControlItem item)
Parameters:itemControlItem

Overrides: ControlItemCollection.SetOwner(ControlItem)

Sort the items from DropDownListItemCollection.

C#
public void Sort()

Sort the items from DropDownListItemCollection.

C#
public void Sort(Func<DropDownListItem, object> predicate)
Parameters:predicateFunc<DropDownListItem, object>

Sort the items from DropDownListItemCollection.

C#
public void Sort(IComparer comparer)
Parameters:comparerIComparer

An object from IComparer interface.