Hello friends,
Can anybody tell how to display the column totals in each column's footer. i.e each columns total should display in its corresponding footer column. When I tried, it is display above the footer and also it is aligned left. I want the total to be displayed exactly below each column.
Please help.
Thanks in advance
Hello,
I was able to do this as follows:
protected void Page_Load(object sender, EventArgs e) { C1WebGrid1.ShowFooter = true; C1WebGrid1.DataBound += (newSender, newE) => { int total = 0; for (int i = 0; i < C1WebGrid1.Items.Count; i++) { total += int.Parse(C1WebGrid1.Items[i].Cells[0].Text); } C1WebGrid1.Columns[0].FooterText = total.ToString(); C1WebGrid1.Columns[1].FooterText = C1WebGrid1.Items.Count.ToString(); C1WebGrid1.Columns[2].FooterText = C1WebGrid1.Items.Count.ToString(); }; }
How were you handling this? Also, please let me know if you have any questions.
Regards,
-Raleigh
Thanks Raleigh for the reply
I solved it in the following way which I got from the post
http://forums.componentone.com/CS/forums/p/69297/190351.aspx#190351
--------------------------------------------
----------------------------------
Thanks a lot for helping me.
Regards
Shivan