Note that there are some explanatory texts on larger screens.

plurals
  1. PONeed to add "rollup" of entire dataset to bottom of DataGrid that is paged
    primarykey
    data
    text
    <p>In ASP.NET 3.5 I have a datagrid that is bound to a somwehat dynamic datatable. The datatable is created by taking three different tables returned from a dataset and combining them to create one table.</p> <p>It goes like this. The first datatable returns a list of the columns that will be in the final datatable. The second datatable returns a list of people, their id number, status info and a grand total that is listed at the end of the row in the final table. The third table returns a list of values for a given type that matches the person id and the column from the first.</p> <p>Example</p> <p>Table1 <br>ProdID &nbsp;&nbsp;&nbsp;ProdName <br>1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Widgets <br>2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Stuff <br>...&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;...</p> <p>Table 2 <br>PersonID &nbsp;&nbsp;&nbsp;PersonName <br>103&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;John Smith <br>105&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Tim Doe <br>...&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;...</p> <p>Table 3 <br>PersonID &nbsp;&nbsp;&nbsp;ProdID &nbsp;&nbsp;&nbsp;Amount <br>103&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1&nbsp;&nbsp;&nbsp;&nbsp;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bsp;&nbsp;&nbsp;Stuff&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;189.00</p> <p>I was able to write a Dictionary that sums each column by name, but I want to show the sum in the footer of the datagrid the end table is bound to.</p> <p>So, the sum below Widgets should be 355 and the sum below Stuff should be 423. The problem is, I can't figure out how to put these values in the footer. I tried OnDataBinding for the grid, but since the footer isn't bound, then it never stops there. I don't know if i can "rollup" the created table.</p> <p>Any ideas? </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload