New to Telerik UI for Blazor? Download Free 30-day trial
TreeList - Excel Export
- EXAMPLE
- VIEW SOURCE
- Change Theme
meridian
Configurator
All Pages
Expand All
| Name | Age | Grade | HireDate |
|---|
| Daryl Sweeney | 67 | 3.2 | 2/8/2012 12:00:00 AM |
| Nevada Hart | 62 | 4.1 | 8/17/2015 12:00:00 AM |
| Hunter Fry | 56 | 3.6 | 2/12/2011 12:00:00 AM |
| Anika Vega | 36 | 4.8 | 2/25/2010 12:00:00 AM |
| Guy Wooten | 65 | 4.5 | 3/4/2010 12:00:00 AM |
| Priscilla Frank | 53 | 3.8 | 12/1/2014 12:00:00 AM |
Page
of 1
1 - 6 of 6 items- Excel-export.razor
- FlatTreeListItemService.cs
- FlatTreeListItemDto.cs
Loading the demo source code...please wait.
Description
You can export the TreeList to an Excel file with a click of a button. Add a TreeListCommandButton with Command="ExcelExport" to the TreeListToolBar to trigger the export. Configure the export through the TreeListExcelExport tag inside TreeListExport.
Key configuration options include:
- FileName - the name of the exported file.
- AllPages - set to
trueto export all data, not only the current page. Note that this requires fetching all data from the data provider. - ExpandAll - set to
trueto export all items in their expanded state, regardless of their current state in the TreeList.
The export also exposes OnBeforeExport and OnAfterExport events so you have full control over the different steps of the export process—for example, to customize the exported data or file before it is downloaded.
This Blazor TreeList Excel Export example is part of a unique collection of hundreds of Blazor demos, with which you can see all Telerik UI for Blazor components and their features in action. View the source code of the demos from the library or directly adapt, and edit them and their theme appearance in Telerik REPL for Blazor or ThemeBuilder.