views:

2839

answers:

1

I am currently using the UltraWebGrid control of Infragistics and I am displaying the sum of values of a column in the footer.

The problem is that, since I am using paging, the total displayed in the footer is being calculated by the values of the current page only, but I want the sum of all the elements in the source, not just the current page

Has anyone experienced this issue before ?

Here is the code:

myGrid.Columns.FromKey("NoOfSubs").Footer.Total = UltraWebGrid.SummaryInfo.Sum
myGrid.Columns.FromKey("NoOfSubs").Footer.Formula = "SUM([NoOfSubs])"

myGrid is the UltraWebGridControl

+1  A: 

I think your best bet here is, unfortunately, to run a separate query to get your totals and use that for the display. This not only solves the problem of the data being summed at the page level, but it also decouples you from the bottom-of-the-table-only positioning restriction with the Infragistics Table Summary.

Rob Allen