System.Web.UI.WebControls Namespace MenuItem Class
.NET Framework version 2.0
Returns the data item bound to the MenuItem control.
Script |
[ Object variable = ] MenuItem.DataItem |
This property can only be used programmatically; it cannot be set when declaring the control.
variable |
An Object that represents the data item bound to the MenuItem control. |
The property is read only with no default value.
Use the DataItem property to access the data item bound to the MenuItem control. The data item is often used to access the field value of the current record in the data source directly.
NOTE: This property is available only after data binding has occurred; otherwise, this property returns a null reference ( Nothing in Visual Basic ).
MenuItem Members