Dart Home | PowerWEB LiveControls for ASP.NET | Custom Development | Reply | PowerWEB LiveControls for ASP.NET Topics | Forums |
Author | Forum: PowerWEB LiveControls for ASP.NET Topic: Problem wth LiveGrid 1.6.2 Footer Doesn't Refresh |
adtelect From: Vancouver, BC Canada Posts: 3 Member Since: 12/05/07 |
posted November 27, 2009 4:33 PM Can you please provide a solution for this problem? Example: Standard LiveGrid EnableFooter = true Added Event ItemDataBound(object sender, DataGridItemEventArgs e) if (e.Item.ItemType == ListItemType.Footer) { e.Item.Cells[0].Text = "Total:"; e.Item.Cells[1].Text = hitCount.ToString(); e.Item.Cells[2].Text = revenue.ToString(); e.Item.Cells[3].Text = expense.ToString(); e.Item.Cells[4].Text = profit.ToString(); } If I change Data in DataGrid (lets say daterange) then all rows refresh OK except the FOOTER. During Debug I can see that DataBind event is triggered but FOOTER is not updated with NEW totals. Please confirm that this is your bug and if you have a fix please let me know |
K M Drake From: Utica, NY USA Posts: 3406 Member Since: 07/14/00 |
posted November 30, 2009 12:51 PM Hi, Do you see the same issue with the trial for version 1.6.3? I added an ItemDataBound handler to the Tutorial sample's LiveDataGrid, and set ShowFooter to true. In this test, the Footer was successfully updated using code similar to yours. Thanks, -ken ------ |
adtelect From: Vancouver, BC Canada Posts: 3 Member Since: 12/05/07 |
posted November 30, 2009 10:21 PM Thank you for your quick Response. We are unable to test 1.6.3 due to some issues with installer. Trial would always hang on Vista and VS 2008. We only have licensed 1.6.2 and our support contract has expired. Terrible place to be in. Is there a way for us to upgrade our license without extra cost, giving the fact that there is a bug and it's not really our fault? Thank you for understanding and your help |
K M Drake From: Utica, NY USA Posts: 3406 Member Since: 07/14/00 |
posted December 1, 2009 11:10 AM Hi, I'm sorry; I was mistaken. While the Footer does update when the page changes in the current version, it does not when a column is sorted. You might try updating the cells by manually sending client-side script. For example, in the Tutorial sample, I added the following ItemDataBound handler which simply updates the "Product Name" footer cell with the current time: protected void LiveDataGrid1_ItemDataBound(object sender, DataGridItemEventArgs e) { if (e.Item.ItemType == ListItemType.Footer) { string s = System.DateTime.Now.ToString(); int count = LiveDataGrid1.Controls[0].Controls.Count; int column = 1; //Product Name e.Item.Cells[column].Text = s; LiveDataGrid1.BufferedScript.Write("document.getElementById(\"" + LiveDataGrid1.Controls[0].Controls[count-1].Controls[column].ClientID + "\").innerHTML=\"" + s + "\";"); } } You should be able to update each footer cell in this manner. Hope it helps, -ken ------ |
adtelect From: Vancouver, BC Canada Posts: 3 Member Since: 12/05/07 |
posted December 1, 2009 2:02 PM Thank you for the workaround. I'll try to use this method and it looks like it might work but I think it should be addressed at a higher level. Cheers |
K M Drake From: Utica, NY USA Posts: 3406 Member Since: 07/14/00 |
posted December 2, 2009 3:41 PM This has been labeled as issue #5160. -ken |
Reply | PowerWEB LiveControls for ASP.NET Topics | Forums |
This site is powered by PowerTCP WebServer for ActiveX |