DataBoundControl.PerformDataBinding Method
Assembly: System.Web (in system.web.dll)
protected void PerformDataBinding ( IEnumerable data )
protected internal function PerformDataBinding ( data : IEnumerable )
Not applicable.
Parameters
- data
The IEnumerable list of data returned from a PerformSelect method call.
Implement this method instead of the DataBind method when you derive a data-bound control from the DataBoundControl class. Placing your control's data-binding logic in PerformDataBinding enables you to avoid the DataBinding and DataBound events being raised in the wrong order.
While the base DataBoundControl class provides no specific implementation for this method, the PerformDataBinding method is called by the PerformSelect method to bind the values of any user interface (UI) controls to the data that is retrieved by the PerformSelect method.
The following code example demonstrates how to implement the PerformDataBinding method in a class derived from DataBoundControl. The TextBoxSet control creates a TextBox control for each data item it is bound to. This code example is part of a larger example provided for the DataBoundControl class.