View on GitHub

dotnet-eud

.NET Controls End-User Documentation

Subtotal Data

The Spreadsheet allows you to automatically group related data in a worksheet and add summary rows to each group using the SUBTOTAL function.

[!IMPORTANT] Before subtotaling, it is necessary to ensure that the range to be subtotaled contains similar data in each column, has column headings in the first row and does not include blank rows or columns.

To insert subtotals for the selected range, follow the steps below.

Since subtotals are specified, you can change the SUBTOTAL function directly in the cell or formula bar to ignore values in the collapsed groups. To do this, add 100 to the first numeric function’s argument, which specifies the code of the function used in calculating subtotals. In this case, the hidden values in the collapsed group will not be taken into account during calculations.

SpreadsheetControl_ChangeSubtotalFunction

To remove subtotals, select a cell in the subtotaled range, invoke the Subtotal dialog and click the Remove All button.