Class ListViewSpreadExport
ListViewSpreadExport is a powerful exporting API, allowing to export RadListView to XLSX, PDF, CSV, and TXT format, utilizing the Document Processing Libraries.
Inheritance
Inherited Members
Namespace: Telerik.WinControls.Export
Assembly: Telerik.WinControls.UI.dll
Syntax
public class ListViewSpreadExport
Constructors
ListViewSpreadExport(RadListView)
Initializes a new instance of the List
Declaration
public ListViewSpreadExport(RadListView radListView)
Parameters
Rad The ListView to export. |
ListViewSpreadExport(RadListView, SpreadExportFormat)
Initializes a new instance of the List
Declaration
public ListViewSpreadExport(RadListView radListView, SpreadExportFormat exportFormat)
Parameters
Rad The ListView to export. |
Spread The export format. |
Properties
CollapsedItemOption
Gets or sets a value indicating how children of collapsed items are exported.
Declaration
public HiddenOption CollapsedItemOption { get; set; }
Property Value
ExportChildItemsGrouped
Gets or sets a value indicating whether to export hierarchy and group child rows grouped.
Declaration
public bool ExportChildItemsGrouped { get; set; }
Property Value
System.
|
ExportFormat
Gets or sets the format of the exported file - XLSX, PDF, CSV, TXT or XLS.
Declaration
public SpreadExportFormat ExportFormat { get; set; }
Property Value
Spread The file extension. |
ExportImages
Gets or sets a value indicating whether to export images.
Declaration
public bool ExportImages { get; set; }
Property Value
System.
|
ExportVisualSettings
Gets or sets a value indicating whether the visual settings should be exported.
Declaration
public bool ExportVisualSettings { get; set; }
Property Value
System.
|
FileExportMode
Specifies how the file will be exported: as a new file, a new sheet in existing file or will override a sheet with given name.
Declaration
public FileExportMode FileExportMode { get; set; }
Property Value
File New |
SheetMaxRows
Gets or sets the maximum number of rows per sheet.
Declaration
[CLSCompliant(false)]
public ExcelMaxRows SheetMaxRows { get; set; }
Property Value
Excel The sheet max rows. |
SheetName
Gets or sets the name of the sheet.
Declaration
public string SheetName { get; set; }
Property Value
System. The name of the sheet. |
Methods
CancelExportAsync()
Cancels an asynchronous export operation.
Declaration
public void CancelExportAsync()
CreateImageOverCell(ListViewSpreadExportCell, Int32, Int32)
Declaration
protected virtual void CreateImageOverCell(ListViewSpreadExportCell cell, int currentRowIndex, int currentColumnIndex)
Parameters
List
|
System.
|
System.
|
CreateSpreadExportCell(ListViewDataItem, Boolean)
Declaration
protected virtual ListViewSpreadExportCell CreateSpreadExportCell(ListViewDataItem listViewDataItem, bool exportAsHidden)
Parameters
List
|
System.
|
Returns
CreateTextCell(ListViewSpreadExportCell, Int32, Int32)
Declaration
protected virtual void CreateTextCell(ListViewSpreadExportCell cell, int currentRowIndex, int currentColumnIndex)
Parameters
List
|
System.
|
System.
|
CreateVisualItem(ListViewDataItem)
Declaration
protected virtual BaseListViewVisualItem CreateVisualItem(ListViewDataItem listViewDataItem)
Parameters
List
|
Returns
GetStylesFromVisualCell(ListViewSpreadExportCell, LightVisualElement)
Declaration
protected virtual void GetStylesFromVisualCell(ListViewSpreadExportCell cell, LightVisualElement visualCell)
Parameters
List
|
Light
|
OnAsyncExportCompleted(AsyncCompletedEventArgs)
Raises the Async
Declaration
protected virtual void OnAsyncExportCompleted(AsyncCompletedEventArgs e)
Parameters
System. The System. |
OnAsyncExportProgressChanged(ProgressChangedEventArgs)
Raises the Async
Declaration
protected virtual void OnAsyncExportProgressChanged(ProgressChangedEventArgs e)
Parameters
System. The System. |
OnCellFormatting(ListViewSpreadExportCellFormattingEventArgs)
Raises the Cell
Declaration
protected virtual void OnCellFormatting(ListViewSpreadExportCellFormattingEventArgs e)
Parameters
List The List |
OnExportCompleted(EventArgs)
Raises the Export
Declaration
protected virtual void OnExportCompleted(EventArgs e)
Parameters
System. The System. |
ReleaseVisualItem(BaseListViewVisualItem)
Declaration
protected virtual void ReleaseVisualItem(BaseListViewVisualItem visualItem)
Parameters
Base
|
RunExport(Stream, ISpreadExportRenderer)
Starts an export operation.
Declaration
public void RunExport(Stream exportStream, ISpreadExportRenderer exportRenderer)
Parameters
System. The stream where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
RunExport(Stream, ISpreadExportRenderer, String)
Starts an export operation, in the specified sheet. If such sheet does not exist, it gets created.
Declaration
public void RunExport(Stream exportStream, ISpreadExportRenderer exportRenderer, string sheetName)
Parameters
System. The stream where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
System. Name of the sheet. |
RunExport(String, ISpreadExportRenderer)
Starts an export operation.
Declaration
public void RunExport(string fileName, ISpreadExportRenderer exportRenderer)
Parameters
System. The file name where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
RunExport(String, ISpreadExportRenderer, String)
Starts an export operation, in the specified sheet. If such sheet does not exist, it gets created.
Declaration
public void RunExport(string fileName, ISpreadExportRenderer exportRenderer, string sheetName)
Parameters
System. The file name where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
System. Name of the sheet. |
RunExportAsync(Stream, ISpreadExportRenderer)
Starts an export operation that runs in a background thread. Note that if ExportVisualSettings is true, collecting the visual styles from the RadListView will still execute on the UI thread.
Declaration
public void RunExportAsync(Stream exportStream, ISpreadExportRenderer exportRenderer)
Parameters
System. The stream where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
RunExportAsync(Stream, ISpreadExportRenderer, String)
Starts an async export operation, in the specified sheet. If such sheet does not exist, it gets created. Note that if ExportVisualSettings is true, collecting the visual styles from the RadListView will still execute on the UI thread.
Declaration
public void RunExportAsync(Stream exportStream, ISpreadExportRenderer exportRenderer, string sheetName)
Parameters
System. The stream where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
System. Name of the sheet. |
RunExportAsync(String, ISpreadExportRenderer)
Starts an export operation that runs in a background thread. Note that if ExportVisualSettings is true, collecting the visual styles from the RadListView will still execute on the UI thread.
Declaration
public void RunExportAsync(string fileName, ISpreadExportRenderer exportRenderer)
Parameters
System. The file name where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
RunExportAsync(String, ISpreadExportRenderer, String)
Starts an async export operation, in the specified sheet. If such sheet does not exist, it gets created. Note that if ExportVisualSettings is true, collecting the visual styles from the RadListView will still execute on the UI thread.
Declaration
public void RunExportAsync(string fileName, ISpreadExportRenderer exportRenderer, string sheetName)
Parameters
System. The file name where data will be exported. |
ISpread Instance of ISpreadExportRenderer class. |
System. Name of the sheet. |
Events
AsyncExportCompleted
Occurs when an async export operation is completed.
Declaration
public event AsyncCompletedEventHandler AsyncExportCompleted
Event Type
System.
|
AsyncExportProgressChanged
Occurs when the progress of an async export operation changes.
Declaration
public event ProgressChangedEventHandler AsyncExportProgressChanged
Event Type
System.
|
CellFormatting
Occurs for every cell that is being exported.
Declaration
public event ListViewSpreadExportCellFormattingEventHandler CellFormatting
Event Type
ExportCompleted
Occurs when the export process completes.
Declaration
public event EventHandler ExportCompleted
Event Type
System.
|