The following are commonly used:
1: E. Item. itemtype = listitemtype. Item | E. Item. itemtype = listitemtype. alternatingitem
The trigger type is the basic row or content row in dadalist.
2: E. Item. itemtype = listitemtype. Header
Indicates the content of the header row in the "dadalist" trigger type.
View the relevant information and see the following information:
For the listitemtype enumeration [C #], see
System. Web. UI. webcontrols namespace | datagriditem. itemtype | datalistitem. itemtype | repeateritem. itemtype
Requirements
Namespace: system. Web. UI. webcontrols
Show all
Specifies the type of items in the list control.
Remarks
Listitemtype enumeration indicates different items that can be included in the list control, such as DataGrid, datalist, and repeater. A typical list control consists of cells that contain elements represented by this enumeration.
Member
Member Name Description
Alternatingitem alternate (an even index starting from scratch) items in cells. It is bound to Data.
The items in editing mode in the edititem list control. It is bound to Data.
Footer of the footer list control. It is not bound to Data.
The header of the header list control. It is not bound to Data.
Items in the item list control. It is bound to Data.
The pager page navigation shows the controls that are located on different pages associated with the DataGrid Control. It is not bound to Data.
Select items in the selecteditem list control. It is bound to Data.
Delimiter between items in the separator list control. It is not bound to Data.
(E. Item. itemtype = listitemtype. Item | E. Item. itemtype = listitemtype. alternatingitem)
Yes. The judgment item is an item in the control content or An interlace item.
"E. Item. itemtype = listitemtype. Header"
Determines whether the item is the control header.
In addition, it is more convenient to obtain the relevant information of the same row in binding. The following content is written in the onitemdatabound event ~~~~
Datarowview myrow = (datarowview) E. Item. dataitem;
Myrow ["here is the name of the relevant field"]