RadGrid for ASP.NET

RadGrid Send comments on this topic.
DataBind Method
See Also 
Telerik.WebControls Namespace > RadGrid Class : DataBind Method


Data-bind MasterTableView and its detail GridTableViews. Prior to calling DataBind, the DataSource property should be assigned.

 

Namespace: Telerik.WebControls
Assembly: RadGrid (in RadGrid.dll)
  

Syntax

Visual Basic (Declaration) 
Overrides Public Sub DataBind() 
Visual Basic (Usage)Copy Code
Dim instance As RadGrid
 
instance.DataBind()
C# 
public override void DataBind()

Remarks

You should have in mind, that in case you are using simple data binding (i.e. when you are not using NeedDataSource event) the correct approach is to call the DataBind() method on the first page load when !Page.IsPostBack and after handling some event (sort event for example).

You will need to assign DataSource and rebind the grid after each operation (paging, sorting, editing, etc.) - this copies exactly MS DataGrid behavior.

We recommend using the RadGrid.Rebind method instead and handling the RadGrid.NeedDataSource event.

Requirements

Platforms: Windows 2000, Windows XP Professional, Windows Server 2003 family

See Also