All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:
<
telerik:GridTemplateColumn
UniqueName
=
"TemplateColumn"
HeaderText
"Row number"
>
ItemTemplate
asp:Label
ID
"numberLabel"
runat
"server"
Width
"30px"
/>
</
HeaderStyle
protected
void
RadGrid1_ItemDataBound(
object
sender, Telerik.Web.UI.GridItemEventArgs e)
{
if
(e.Item
is
GridDataItem && e.Item.OwnerTableView.DataSourceID ==
"SqlDataSource1"
)
Label lbl = e.Item.FindControl(
as
Label;
lbl.Text = (e.Item.ItemIndex + 1).ToString();
}
"Row"
Text='<%# (Container as GridItem).ItemIndex + 1 %>' />