Change GroupPanel Text

6 posts, 0 answers
  1. Vance Smith
    Vance Smith avatar
    36 posts
    Member since:
    Jun 2012

    Posted 04 Jan 2013 Link to this post


    I would like to change the GroupPanel Text. Currently it says, "Drag a column here to group by that column.". I would like it to say something else.

    Can someone please assist.


  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 07 Jan 2013 Link to this post


    Try the following code snippet to achieve your scenario.

    this.radGridView1.TableElement.GridViewElement.GroupPanelElement.Text = "some text";

    Hope this helps.

  3. Anton
    Anton avatar
    167 posts

    Posted 09 Jan 2013 Link to this post

    Hello Vance,

    Thank you Princy for provided help.

    The provided code is correct. Just for your information, the GridViewElement can be accessed directly through the control as well:
    this.radGridView1.GridViewElement.GroupPanelElement.Text = "Your Custom text 1";

    Also, you need to handle the case when user clears the groups, because the grid will reset the text to the default one. This can be achieved by subscribing to the GroupByChanged event:
    void radGridView1_GroupByChanged(object sender, GridViewCollectionChangedEventArgs e)
        if (e.GridViewTemplate.GroupDescriptors.Count == 0)
            this.radGridView1.GridViewElement.GroupPanelElement.Text = "Your Custom text 1";

    This topic is also discussed in the following forum thread:

    I hope this helps.

    All the best,
    the Telerik team
    Q3'12 SP1 of RadControls for WinForms is out now. See what's new.
  4. fariba
    fariba avatar
    21 posts
    Member since:
    May 2014

    Posted 21 Sep 2015 Link to this post

    I want to change the height of  GroupPanelElement by changing the height value in
       this.radGridView1.GridViewElement.GroupPanelElement.Size = new Size(this.radGridView1.Width, 200);
    nothing would be happened and value came back to 23 which is set for it as a default value​.
    What should I do?

    Best regards,
  5. Dess
    Dess avatar
    2101 posts

    Posted 21 Sep 2015 Link to this post

    Hello Faqriba,

    Thank you for writing.
    Instead of setting the Size property, you can set the MinSize property to increase the group panel's height:
    this.radGridView1.GridViewElement.GroupPanelElement.MinSize = new Size(this.radGridView1.Width, 200);

    I hope this information helps. Should you have further questions I would be glad to help.
    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
  6. fariba
    fariba avatar
    21 posts
    Member since:
    May 2014

    Posted 21 Sep 2015 in reply to Dess Link to this post

    Dear dess

    yes It works 

    Thank You


Back to Top