This is a migrated thread and some comments may be shown as answers.

Setting GroupPanel Text in code behind.

1 Answer 88 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Brent
Top achievements
Rank 1
Brent asked on 01 Aug 2008, 12:51 PM
I'm setting the GroupPanel Text property of a Grid, programmatically (in code behind of the page that contains the grid).

The GroupPanel is being displayed, but the Text property is NOT being displayed.

If I step through the code behind with a watch on the Grid.GroupPanel, the Text property DOES show my text.  Yet the GroupPanel is blank when the page is displayed.

Also, if I view source on the page, my text has not been sent back to the browser.

I have tried setting the text both in Page_PreRender and on the grid's PreRender, like this:

RadGridLookupTable.GroupPanel.Text =

"MY TEST TEXT";

Both methods are called and execute, but the text still does NOT show up in the grid's group panel.

Any ideas where my text might be getting lost?

Thanks In Advance.

1 Answer, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 01 Aug 2008, 02:13 PM
Hello Brent,

Try modifying the GroupPanel text in the RadGrid's OnDataBound :

        <telerik:RadGrid  ID="RadGrid2"  runat="server"  OnDataBound="RadGrid2_DataBound" />


        protected void RadGrid2_DataBound(object sender, EventArgs e)
        {
            RadGrid2.GroupPanel.Text = "MyText";
        }

If you still have no success, please copy/paste your RadGrid declaration and relevant code-behind here.

All the best,
Dimo
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Grid
Asked by
Brent
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Share this question
or