Dear Support,
Thanks for the below link, which helps me to solve the issue in showing the total in header row.
http://es.infragistics.com/community/forums/t/45274.aspx
Now I'm facing an another issue, is that I've a webdatagrid with more than 1000 rows and am doing the running total on the header.
Total which shows on the header is not always correct, because it considers only 140 rows. Also the virtual scrolling is enabled on the grid.
If i remove the virtual scrolling then the total is perfect, but i do want to enable the virtual scrolling.
Any help will be greatly appreciated.
Regards,
Sam
Hello Sam,
I am assuming in this scenario you are attempting to sum the rows on the client ? As when VirtualScrolling is enabled rows are fetched to the client in batches (and the whole column sum may not be calculated), I would suggest calculating the header value on the server. Attached is a sample illustrating that scenario in practice (with row count in this case for simplicity). Note that in this case the use of a HeaderTemplate is shown, however for textual data, the header text may be used as well:
protected void Page_Load(object sender, EventArgs e) { WebDataGrid1.DataSource = populateGrid(); WebDataGrid1.DataBind(); (WebDataGrid1.Columns[0].Header.TemplateContainer.FindControl("Label1") as Label).Text = populateGrid().Rows.Count.ToString(); }
Hope this helps. Please do not hesitate to contact me if you have any questions.