Grids
Example of Editing in ASP.NET Core Pivot Table Control
This sample demonstrates CRUD operations performed over the raw items of any value cell in a pivot table. Different types of cell editing options are provided to make editing simpler.
FY 2015 | FY 2016 | FY 2017 | FY 2018 | Grand Total | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
In Stock | Units Sold | Sold Amount | In Stock | Units Sold | Sold Amount | In Stock | Units Sold | Sold Amount | In Stock | Units Sold | Sold Amount | In Stock | Units Sold | Sold Amount | |
France | 5066 | 46939 | $19,097,073.84 | 5248 | 44513 | $19,575,092.52 | 5581 | 48207 | $18,251,898.21 | 1152 | 11516 | $5,553,761.57 | 17047 | 151175 | $62,477,826.14 |
Germany | 5614 | 44154 | $16,903,257.27 | 5523 | 47910 | $18,081,139.06 | 5462 | 47214 | $18,479,733.38 | 1347 | 11419 | $5,042,868.49 | 17946 | 150697 | $58,506,998.2 |
United Kingdom | 2864 | 25457 | $18,197,943.25 | 2991 | 23944 | $15,422,056.5 | 2924 | 25836 | $17,740,233 | 811 | 6375 | $5,236,607.5 | 9590 | 81612 | $56,596,840.25 |
United States | 5171 | 47724 | $16,224,668.54 | 5442 | 47691 | $17,915,993.08 | 4823 | 46602 | $20,120,714.29 | 1199 | 11715 | $4,352,331.85 | 16635 | 153732 | $58,613,707.76 |
Grand Total | 18715 | 164274 | $70,422,942.9 | 19204 | 164058 | $70,994,281.16 | 18790 | 167859 | $74,592,578.88 | 4509 | 41025 | $20,185,569.41 | 61218 | 537216 | $236,195,372.4 |
Properties
|
|
|
|
In the sample, the raw items of any value cell can be viewed in a drill-through dialog by double-clicking the cell. CRUD operations can be performed by double-clicking the cells or using toolbar options. The following CRUD operations can be performed through toolbar operations for normal and batch edits:
Add
- To add new record, clickAdd
in the toolbar.Edit
- To edit record, double click a cell.Delete
- To delete a record, clickDelete
in the toolbar after selected a row.Update
,Cancel
- You can save or discard changes by clickingUpdate
orCancel
in the toolbar, respectively.
This CRUD operations can be configured in a pivot table using editSettings
in code behind. There are also
different modes to manipulate the data source.
The available modes are:
-
Normal
- Editing by row. -
Batch
- Editing individual cells and bulk updating. -
Dialog
- Editing by row with a dialog option. -
Command Columns
- An additional column appends to the data grid with icons to perform CRUD operations. Editing using cell double-click is restricted here.