This documentation is archived and is not being maintained.

ListItem Members

ListItem overview

Public Constructors

public constructorListItem Constructor Overloaded. Initializes a new instance of the ListItem class.

Public Properties

public propertyAttributes Gets a collection of attribute name and value pairs for the ListItem that are not directly supported by the class.
public propertySelected Gets or sets a value indicating whether the item is selected.
public propertyText Gets or sets the text displayed in a list control for the item represented by the ListItem.
public propertyValue Gets or sets the value associated with the ListItem.

Public Methods

public methodEquals Overridden. See Object.Equals.
public methodstatic (Shared in Visual Basic)FromString Creates a ListItem from the specified text.
public methodGetHashCode Overridden. See Object.GetHashCode.
public methodGetType (inherited from Object) Gets the Type of the current instance.
public methodToString Overridden. See Object.ToString.

Protected Methods

protected methodFinalize (inherited from Object) Overridden. Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.

In C# and C++, finalizers are expressed using destructor syntax.

protected methodMemberwiseClone (inherited from Object) Creates a shallow copy of the current Object.

See Also

ListItem Class | System.Web.UI.WebControls Namespace