System.Web.UI.WebControls.ListItemCollection Members

The members of System.Web.UI.WebControls.ListItemCollection are listed below.

See Also: Inherited members from System.Object

Public Constructors

Initializes a new instance of the System.Web.UI.WebControls.ListItemCollection class.

Public Properties

Capacityint.

Gets or sets the maximum number of items that the System.Web.UI.WebControls.ListItemCollection can store.

[read-only]
Countint.

Gets the number of System.Web.UI.WebControls.ListItem objects in the collection.

[read-only]
IsReadOnlybool.

Gets a value indicating whether the System.Web.UI.WebControls.ListItemCollection is read-only.

[read-only]
IsSynchronizedbool.

Gets a value indicating whether access to the System.Web.UI.WebControls.ListItemCollection is synchronized (thread-safe).

[read-only]
default property
Item(int)ListItem. Documentation for this section has not yet been entered.
[read-only]
SyncRootobject.

Gets the object that can be used to synchronize access to the System.Web.UI.WebControls.ListItemCollection.

Public Methods

Add(string)

Appends a System.Web.UI.WebControls.ListItem to the end of the collection that represents the specified string.

Add(ListItem)

Appends the specified System.Web.UI.WebControls.ListItem to the end of the collection.

AddRange(ListItem[])

Adds the items in an array of System.Web.UI.WebControls.ListItem objects to the collection.

Clear()

Removes all System.Web.UI.WebControls.ListItem objects from the collection.

Contains(ListItem) : bool

Determines whether the collection contains the specified item.

CopyTo(Array, int)

Copies the items from the System.Web.UI.WebControls.ListItemCollection to the specified Array, starting with the specified index.

FindByText(string) : ListItem

Searches the collection for a System.Web.UI.WebControls.ListItem with a ListItem.Text property that equals the specified text.

FindByValue(string) : ListItem

Searches the collection for a System.Web.UI.WebControls.ListItem with a ListItem.Value property that contains the specified value.

GetEnumerator() : IEnumerator

Returns a IEnumerator implemented object that contains all System.Web.UI.WebControls.ListItem objects in the System.Web.UI.WebControls.ListItemCollection.

IndexOf(ListItem) : int

Determines the index value that represents the position of the specified System.Web.UI.WebControls.ListItem in the collection.

Insert(int, string)

Inserts a System.Web.UI.WebControls.ListItem which represents the specified string in the collection at the specified index location.

Insert(int, ListItem)

Inserts the specified System.Web.UI.WebControls.ListItem in the collection at the specified index location.

Remove(string)

Removes a System.Web.UI.WebControls.ListItem from the collection that represents the specified string.

Remove(ListItem)

Removes the specified System.Web.UI.WebControls.ListItem from the collection.

RemoveAt(int)

Removes the System.Web.UI.WebControls.ListItem at the specified index from the collection.

Explicitly Implemented Interface Members

IList.Add

For a description of this member, see IList.Add(object).

IList.Contains

For a description of this member, see IList.Contains(object).

IList.IndexOf

For a description of this member, see IList.IndexOf(object).

IList.Insert

For a description of this member, see IList.Insert(int, object).

[read-only]
IList.IsFixedSizebool.

For a description of this member, see IList.IsFixedSize.

[read-only]
System.Web.UI.IStateManager.IsTrackingViewStatebool.

For a description of this member, see System.Web.UI.IStateManager.IsTrackingViewState.

IList.Itemobject. Documentation for this section has not yet been entered.
System.Web.UI.IStateManager.LoadViewState

Loads the previously saved state.

IList.Remove

For a description of this member, see IList.Remove(object).

System.Web.UI.IStateManager.SaveViewState

Returns object containing state changes.

System.Web.UI.IStateManager.TrackViewState

Starts tracking state of changes.