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

footer in gridview

3 Answers 513 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Mona
Top achievements
Rank 1
Mona asked on 07 Mar 2010, 12:09 PM
dear support
I have downloaded your trial version of telerik-radcontrols for-winforms q2-2009 sp1 and need to access grid footer to add total row in grid
could you hepl me plz

3 Answers, 1 is accepted

Sort by
0
Accepted
Nick
Telerik team
answered on 08 Mar 2010, 10:20 AM
Hello Mona ,

Thank you for contacting us. Please refer to our Demo application --> RadGridView --> Grouping --> Group Summaries. There you can see two examples. I copied one of them for your convenience:

GridViewSummaryRowItem item1 = new GridViewSummaryRowItem();            item1.Add(new GridViewSummaryItem("Freight", "Sum: {0:F2}; ", GridAggregateFunction.Sum));            this.radGridViewDemo.MasterGridViewTemplate.SummaryRowsBottom.Add(item1);

Do not hesitate to write me back if you have further questions.

Sincerely yours,
Nick
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Mona
Top achievements
Rank 1
answered on 14 Mar 2010, 02:08 PM
Thanks it works great now but how can I change GridViewSummaryRowItem background color ?
0
Jack
Telerik team
answered on 18 Mar 2010, 09:42 AM
Hello Mona ,

You should handle ViewCellFormatting event to customize summary cell style. Here is a sample:
void radGridView1_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
    if (e.CellElement is GridSummaryCellElement)
    {
        e.CellElement.DrawFill = true;
        e.CellElement.GradientStyle = GradientStyles.Solid;
        e.CellElement.BackColor = Color.Beige;
    }
}

 


Kind regards,
Jack
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
Tags
GridView
Asked by
Mona
Top achievements
Rank 1
Answers by
Nick
Telerik team
Mona
Top achievements
Rank 1
Jack
Telerik team
Share this question
or