DataListItemEventArgs Class
Provides data for the ItemCreated and ItemDataBound events of a DataList control. This class cannot be inherited.
Assembly: System.Web (in System.Web.dll)
The ItemCreated event is raised when an item in the DataList control is created.
The ItemDataBound event is raised when an item in the DataList control is data bound to a source.
For a list of initial property values for an instance of DataListItemEventArgs, see the DataListItemEventArgs constructor.
For more information about handling events, see Consuming Events.
The following example demonstrates how to define a handler for the ItemDataBound event. The code in the handler calculates the price of items in a DataList control. This example specifies the event handler declaratively, setting the event handler for the OnItemDataBound attribute of the DataList control.
The following example demonstrates how to specify the event handler and programmatically add it to the ItemDataBound event in the Page_Load method.
- AspNetHostingPermission
for operating in a hosted environment. Demand value: LinkDemand; Permission value: Minimal.
- AspNetHostingPermission
for operating in a hosted environment. Demand value: InheritanceDemand; Permission value: Minimal.
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.