Grid Header Localized

2 posts, 0 answers
  1. Per Holmqvist
    Per Holmqvist avatar
    194 posts
    Member since:
    Nov 2002

    Posted 05 Aug 2015 Link to this post

    I know that I can localize the GridHeaders like the below


    Protected Sub MyGrid_ItemCreated(ByVal sender As Object, ByVal e As GridItemEventArgs) Handles MyGrid.ItemCreated​

      If TypeOf e.Item Is GridHeaderItem Then
        Dim headerItem As GridHeaderItem = CType(e.Item, GridHeaderItem)

        Dim header As GridHeaderItem = CType(e.Item, GridHeaderItem)

        header.Cells(9).Text = Resources.PageLocalizations.GridHeaderApp
        header("Active").Text = Resources.PageLocalizations.GridHeaderActive​

      End If

    End Sub


    But the headers in Insert/edit mode doesn't get changed when using EditMode="PopUp"

    Anyone knows how to edit the headers there?


    Best Regards Pelle

  2. Eyup
    Eyup avatar
    3962 posts

    Posted 07 Aug 2015 Link to this post

    Hi Pelle,

    You can use the following approach to achieve this requirement:
    protected void RadGrid1_DataBinding(object sender, EventArgs e)
        foreach (GridColumn col in RadGrid1.MasterTableView.RenderColumns)
            if (col.UniqueName == "ShipName")
                col.HeaderText = "Success";

    That should do the trick. Please give it a try and let me know if it works for you.

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top