Tritium UI
TritiumPivotGrid
Turn a flat list into a row, column, and value matrix with totals.
Key features
- Assign fields to rows, columns, and values and aggregate with sum, count, average, min, or max.
- Show row totals, column totals, and subtotals.
- Sort by the row label or by a data column, ascending or descending.
- Format numbers and choose the text shown for empty cells.
- Expand and collapse groups.
- Embed a field list, or share the same field collections with a separate TritiumPivotFieldList.
- Select a cell and handle CellTapped.
- Export the matrix to CSV or to a PNG.
- This is a flat-list pivot, not an OLAP cube.
Platforms
Android, iOS, Mac Catalyst, and Windows 10 version 19041 and later (.NET 10 MAUI).
Main API
- ItemsSource . The flat rows to reshape.
- RowFields . Fields that become row headers; ColumnFields and ValueFields complete the layout.
- ShowRowTotals . Adds a total column; ShowColumnTotals and ShowSubtotals are the matching switches.
- CellTapped . Fires with the pivot cell and its row and column indexes.
Basic example
Declare this namespace on the page.
xmlns:pivot="clr-namespace:Tritium.Maui.Pivot;assembly=Tritium.Maui.Pivot"
<pivot:TritiumPivotGrid ItemsSource="{Binding Sales}"
ShowRowTotals="True"
ShowColumnTotals="True"
ValueFormat="0.##" /> Add the package source from your license, then reference the package that includes this control. These packages are not on the public NuGet Gallery.