it is very important to know when particular event will fire in data-bound control.
To help you understand the relationship between the page life cycle and data binding events, the following table lists data-related events in data-bound controls such as the GridView, DetailsView, and FormView controls.
To help you understand the relationship between the page life cycle and data binding events, the following table lists data-related events in data-bound controls such as the GridView, DetailsView, and FormView controls.
Control Event | Typical Use |
---|---|
DataBinding |
|
RowCreated (GridView only) or ItemCreated (DataList, DetailsView, SiteMapPath, DataGrid, FormView, Repeater, and ListView controls) |
|
RowDataBound (GridView only) or ItemDataBound (DataList, SiteMapPath, DataGrid, Repeater, and ListView controls) |
|
DataBound |
|
Nested Data-Bound Controls
- put the data source control for the Child control in the same template item as the Child control itself, and do not set the data binding properties of the Child control declaratively.
- Instead, set them programmatically at run time during the RowDataBound event, so that the Child control does not bind to its data until the ParentId information is available.
No comments:
Post a Comment