Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Items Property

ListControl::Items Property

Gets the collection of items in the list control.

Namespace:  System.Web.UI.WebControls
Assembly:  System.Web (in System.Web.dll)

[PersistenceModeAttribute(PersistenceMode::InnerDefaultProperty)]
public:
virtual property ListItemCollection^ Items {
	ListItemCollection^ get ();
}

Property Value

Type: System.Web.UI.WebControls::ListItemCollection
A ListItemCollection that represents the items within the list. The default is an empty list.

Use this property to get the properties of items in the list control. This property can be used to determine the selected items in the list control.

TopicLocation
How to: Set Web Server Control Properties in CollectionsBuilding ASP .NET Web Applications
How to: Set Web Server Control Properties in CollectionsBuilding ASP .NET Web Applications

The following example demonstrates how to use the Items property to determine the selected items in a CheckBoxList control.

No code example is currently available or this language may not be supported.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0, 1.1, 1.0

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Community Additions

ADD
Show:
© 2015 Microsoft