WinForms

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class GridGroupingExcelConverterControl

    Show / Hide Table of Contents

    Class GridGroupingExcelConverterControl

    Implements the exporting functionalities of GridGroupingControl to Excel.

    Inheritance
    System.Object
    GridGroupingExcelConverterBase
    GridGroupingExcelConverterControl
    Inherited Members
    GridGroupingExcelConverterBase.DEF_RIGHT_ANGLE
    GridGroupingExcelConverterBase.DEF_MAXIMUM_ANGLE
    GridGroupingExcelConverterBase.DEF_MINIMUM_SUPPORTED_ANGLE
    GridGroupingExcelConverterBase.CreateEngine()
    GridGroupingExcelConverterBase.ExportCellValue(GridStyleInfo, IWorksheet, Int32, Int32)
    GridGroupingExcelConverterBase.ExportStyles(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportFormula(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportHyperLink(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportAlignment(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportBorderStyles(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportBackcolor(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportBorderStyle(GridBorder, IBorder)
    GridGroupingExcelConverterBase.ExportNumberFormat(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportFontStyles(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportImage(GridStyleInfo, IRange)
    GridGroupingExcelConverterBase.ExportStyle
    GridGroupingExcelConverterBase.ExportBorders
    GridGroupingExcelConverterBase.ExportMode
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Syncfusion.GroupingGridExcelConverter
    Assembly: Syncfusion.GridConverter.Windows.dll
    Syntax
    public class GridGroupingExcelConverterControl : GridGroupingExcelConverterBase
    Remarks

    The GridGroupingExcelConverterControl class provides support for exporting the GridGroupingControl with the efficient way. The grid will be exported with various options and optimized way.

    Constructors

    GridGroupingExcelConverterControl()

    Initializes a new instance of the GridGroupingExcelConverterControl class.

    Declaration
    public GridGroupingExcelConverterControl()

    Properties

    AllowGroupOutlining

    Gets or sets a value indicating whether Grouping outlining has to be exported

    Declaration
    public bool AllowGroupOutlining { get; set; }
    Property Value
    Type Description
    System.Boolean

    AllowNestedTableOutling

    Gets or sets a value indicating whether nested table outlining has to be exported.

    Declaration
    public bool AllowNestedTableOutling { get; set; }
    Property Value
    Type Description
    System.Boolean

    ApplyExcelFilter

    Gets or sets a value indicating whether Excel filter has to be applied for Excel columns.

    Declaration
    public bool ApplyExcelFilter { get; set; }
    Property Value
    Type Description
    System.Boolean

    CanExportColumnWidth

    Gets or sets a value indicating whether grid's column width has to be exported to Excel. If you want to disable this column width, you can set False and assign your needed RowHeight in DefaultRowHeight property.

    Declaration
    public bool CanExportColumnWidth { get; set; }
    Property Value
    Type Description
    System.Boolean

    CanExportRowHeight

    Gets or sets a value indicating whether grid's rowheight has to be exported to Excel. If you want to disable this rowheight, you can set False and assign your needed RowHeight in DefaultRowHeight property.

    Declaration
    public bool CanExportRowHeight { get; set; }
    Property Value
    Type Description
    System.Boolean

    DefaultColumnWidth

    Gets or sets the default column width in Excel sheet for all columns. This is applicable when disabling CanExportColumnWidth

    Declaration
    public int DefaultColumnWidth { get; set; }
    Property Value
    Type Description
    System.Int32

    DefaultRowHeight

    Gets or sets the default row height in Excel sheet for all rows. This is applicable when disabling CanExportRowHeight

    Declaration
    public int DefaultRowHeight { get; set; }
    Property Value
    Type Description
    System.Int32

    EnableOptimization

    Exports the data without creating style for grid cell. The data will be get from table engine with column number format. If this is true, Border and styles will not be exported and cell data will be taken from record directly instead of getting it from cell style.

    Declaration
    public bool EnableOptimization { get; set; }
    Property Value
    Type Description
    System.Boolean

    ExcelVersion

    Gets or sets the Excel engine version.

    Declaration
    public ExcelVersion ExcelVersion { get; set; }
    Property Value
    Type Description
    ExcelVersion

    ExportNestedTableCaption

    Gets or sets a value indicating whether nested table's caption and outlining of inner tables has to be exported.

    Declaration
    public bool ExportNestedTableCaption { get; set; }
    Property Value
    Type Description
    System.Boolean

    ShowGridLines

    Gets or sets a value indicating whether gridlines has to be shown in excel sheet.

    Declaration
    public bool ShowGridLines { get; set; }
    Property Value
    Type Description
    System.Boolean

    Methods

    ExportCaptionRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, Stack, IWorksheet, ExcelExportingOptions)

    Exports the caption row to excel sheet.

    Declaration
    protected virtual void ExportCaptionRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, Stack groupStartIndexes, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element of the table.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections.

    System.Int32 excelRowIndex

    Destination row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    System.Collections.Stack groupStartIndexes

    Stack indices for setting the grouping.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters passed with null.

    System.ArgumentException

    If row index is less or equal to 0.

    ExportCaptionSummaryCell(Element, GridVisibleColumnDescriptor, IRange)

    Exports the caption summary cell to Excel sheet cell.

    Declaration
    protected virtual void ExportCaptionSummaryCell(Element element, GridVisibleColumnDescriptor visibleColumn, IRange excelRange)
    Parameters
    Type Name Description
    Element element

    The table element associated with Record cell.

    GridVisibleColumnDescriptor visibleColumn

    The corresponding visible column descriptor.

    IRange excelRange

    The destination worksheet range.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If element, visibleColumn or excelRange is null.

    ExportCaptionSummaryRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, Int32, Int32, IWorksheet)

    Exports the caption summaries to Excel sheet.

    Declaration
    protected virtual void ExportCaptionSummaryRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet)
    Parameters
    Type Name Description
    Element element

    The element of the table.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    Destination row index.

    System.Int32 excelStartColumnIndex

    Excel start column index. i.e. from which column cell has to be exported in Excel sheet.

    IWorksheet sheet

    The destination worksheet.

    Exceptions
    Type Condition
    System.ArgumentNullException

    if any of the parameters such as element,sheet,tableDescriptor are null.

    System.ArgumentException

    if excelRowIndex is less than or equal to 0..

    ExportColumnHeaderCell(Element, GridVisibleColumnDescriptor, IRange)

    Exports the column header cell to Excel sheet cell.

    Declaration
    protected virtual void ExportColumnHeaderCell(Element element, GridVisibleColumnDescriptor visibleColumn, IRange excelRange)
    Parameters
    Type Name Description
    Element element

    The table element associated with Record cell.

    GridVisibleColumnDescriptor visibleColumn

    The corresponding visible column descriptor.

    IRange excelRange

    The destination worksheet range.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If element, visibleColumn or excelRange is null.

    ExportColumnHeaderRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the column headers to Excel sheet.

    Declaration
    protected virtual void ExportColumnHeaderRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element of the table.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    Destination row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,excelRowIndex,tableDescriptor,visibleColumns,excelStartColumnIndex are null.

    ExportColumnWidth(GridGroupingControl, IWorksheet, GridTableDescriptor, ExcelExportingOptions)

    Exports the columns widths to Excel sheet columns.

    Declaration
    protected virtual void ExportColumnWidth(GridGroupingControl grid, IWorksheet sheet, GridTableDescriptor tableDescriptor, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    GridGroupingControl grid

    The GridGroupingControl that needs to be exported

    IWorksheet sheet

    Destination worksheet

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as grid,sheet tableDescriptor,exportingOptions are null.

    ExportCoveredRanges(GridGroupingControl, IWorksheet)

    Exports the style and data of merged cells from the grid.

    Declaration
    protected virtual void ExportCoveredRanges(GridGroupingControl grid, IWorksheet sheet)
    Parameters
    Type Name Description
    GridGroupingControl grid

    GridGroupingControl

    IWorksheet sheet

    IWorksheet to import

    Exceptions
    Type Condition
    System.ArgumentNullException

    If grid or sheet is null.

    ExportGroupFooterRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the Group footer row to Excel sheet.

    Declaration
    protected virtual void ExportGroupFooterRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    The target excel row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,excelRowIndex,tableDescriptor are null.

    ExportGroupHeaderRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the Group header footer row to Excel sheet.

    Declaration
    protected virtual void ExportGroupHeaderRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    The target row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,excelRowIndex,tableDescriptor are null.

    ExportGroupingOutline(GridTableDescriptor, Int32, Int32, IWorksheet, Stack, ExcelExportingOptions)

    Exports the grouping outline as it is in GridGroupingControl.

    Declaration
    protected virtual void ExportGroupingOutline(GridTableDescriptor tableDescriptor, int groupLevel, int excelRowIndex, IWorksheet sheet, Stack groupStartIndexes, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    GridTableDescriptor tableDescriptor

    The table descriptor which has the table.

    System.Int32 groupLevel

    The element group level. It should be Zero if it is last group in the Grid.

    System.Int32 excelRowIndex

    The Excel row index.

    IWorksheet sheet

    Destination worksheet.

    System.Collections.Stack groupStartIndexes

    The stack which holds the row index which is the start index of the group.

    ExcelExportingOptions exportingOptions

    The ExcelExportingOptions for customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    if any of the parameters such as groupStartIndexes,excelRowIndex,exportingOptions are null.

    ExportGroupPreviewRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the GroupPreviewRow to Excel sheet.

    Declaration
    protected virtual void ExportGroupPreviewRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    The target row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,excelRowIndex,tableDescriptor are null.

    ExportNestedTables(Record, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the nested table's elements to Excel sheet.

    Declaration
    protected virtual void ExportNestedTables(Record record, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Record record

    The parent record that hold the nested tables.

    System.Int32 excelRowIndex

    Destination row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells(indent cell). This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If record or exportingOptions is null.

    System.ArgumentException

    If excelRowIndex or excelStartColumnIndex is null.

    ExportPreviewCell(Element, GridStyleInfo, IRange)

    Exports the preview cell such as RecordPreviewRow,GroupPreviewRow, GroupHeader, GroupFooter cell to Excel sheet cell.

    Declaration
    protected virtual void ExportPreviewCell(Element element, GridStyleInfo cellStyle, IRange excelRange)
    Parameters
    Type Name Description
    Element element

    The table element associated with Record cell.

    GridStyleInfo cellStyle

    The grid cell style.

    IRange excelRange

    The destination worksheet range.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If element, cellStyle or excelRange is null.

    ExportRecordCell(Element, GridVisibleColumnDescriptor, IRange)

    Exports the record cell to Excel sheet.

    Declaration
    protected virtual void ExportRecordCell(Element element, GridVisibleColumnDescriptor visibleColumn, IRange excelRange)
    Parameters
    Type Name Description
    Element element

    The table element associated with Record cell.

    GridVisibleColumnDescriptor visibleColumn

    The corresponding visible column descriptor.

    IRange excelRange

    The destination worksheet range.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If element, visibleColumn or excelRange is null.

    ExportRecordPreviewRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the RecordPreview row to Excel sheet.

    Declaration
    protected virtual void ExportRecordPreviewRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    The target row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,exportingOptions,excelRowIndex,tableDescriptor,visibleColumns,excelStartColumnIndex are null.

    ExportRecordRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the records to Excel sheet.

    Declaration
    protected virtual void ExportRecordRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The table element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    The visible columns collections of the table.

    System.Int32 excelRowIndex

    The target row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    The destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,excelRowIndex,tableDescriptor,visibleColumns,excelStartColumnIndex are null.

    ExportStackedHeaderCell(Element, GridVisibleColumnDescriptor, IRange)

    Exports the stacked header cell to Excel sheet.

    Declaration
    protected virtual void ExportStackedHeaderCell(Element element, GridVisibleColumnDescriptor visibleColumn, IRange excelRange)
    Parameters
    Type Name Description
    Element element

    The table element associated with Record cell.

    GridVisibleColumnDescriptor visibleColumn

    The corresponding visible column descriptor.

    IRange excelRange

    The destination worksheet range.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If element, visibleColumn or excelRange is null.

    ExportStackedHeaderRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, IWorksheet, ExcelExportingOptions)

    Exports the stacked headers to Excel sheet.

    Declaration
    protected virtual void ExportStackedHeaderRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    The target row index.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,excelRowIndex,tableDescriptor,exportingOptions,visibleColumns are null.

    ExportSummaryCell(Element, GridVisibleColumnDescriptor, IRange)

    Exports the summary cell to Excel sheet.

    Declaration
    protected virtual void ExportSummaryCell(Element element, GridVisibleColumnDescriptor visibleColumn, IRange excelRange)
    Parameters
    Type Name Description
    Element element

    The table element associated with Record cell.

    GridVisibleColumnDescriptor visibleColumn

    The corresponding visible column descriptor.

    IRange excelRange

    The destination worksheet range.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If element, visibleColumn or excelRange is null.

    ExportSummaryRow(Element, GridTableDescriptor, GridVisibleColumnDescriptorCollection, ref Int32, Int32, IWorksheet, ExcelExportingOptions)

    Exports the summary rows to Excel sheet.

    Declaration
    protected virtual void ExportSummaryRow(Element element, GridTableDescriptor tableDescriptor, GridVisibleColumnDescriptorCollection visibleColumns, ref int excelRowIndex, int excelStartColumnIndex, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    Element element

    The element to export.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    GridVisibleColumnDescriptorCollection visibleColumns

    Visible columns collections of the table.

    System.Int32 excelRowIndex

    The current row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    IWorksheet sheet

    Destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as element,sheet ,tableDescriptor,exportingOptions,excelStartColumnIndex are null.

    System.ArgumentException

    If excelRowIndex is less than or equal to 0..

    ExportTable(IList, GridTableDescriptor, ref Int32, Int32, Boolean, IWorksheet, ExcelExportingOptions)

    Exports the grid table to Excel sheet.

    Declaration
    protected virtual void ExportTable(IList tableElements, GridTableDescriptor tableDescriptor, ref int excelRowIndex, int excelStartColumnIndex, bool isNestedTable, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    System.Collections.IList tableElements

    The elements belongs to table.

    GridTableDescriptor tableDescriptor

    The TableDescriptor of the ParentTable.

    System.Int32 excelRowIndex

    The target row index.

    System.Int32 excelStartColumnIndex

    The start column for exporting the cells. This is mainly used for hierarchy export.

    System.Boolean isNestedTable

    Determines whether this is an nested table.

    IWorksheet sheet

    The destination worksheet.

    ExcelExportingOptions exportingOptions

    Excel exporting options for some customization.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as tableElements,sheet ,excelRowIndex,tableDescriptor,exportingOptions,excelStartColumnIndex are null.

    ExportToExcel(GridGroupingControl, IWorksheet, ExcelExportingOptions)

    Exports the GridGroupingControl to Excel with various exporting options.

    Declaration
    public virtual void ExportToExcel(GridGroupingControl grid, IWorksheet sheet, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    GridGroupingControl grid

    The GridGroupingControl that needs to be exported.

    IWorksheet sheet

    The destination IWorksheet.

    ExcelExportingOptions exportingOptions

    The ExcelExportingOptions.

    Exceptions
    Type Condition
    System.ArgumentNullException

    If any of the parameters such as grid,sheet are null.

    ExportToExcel(GridGroupingControl, String, ExcelExportingOptions)

    Exports the GridGroupingControl to Excel which reads from specified file name with various exporting option.

    Declaration
    public virtual void ExportToExcel(GridGroupingControl grid, string excelFileName, ExcelExportingOptions exportingOptions)
    Parameters
    Type Name Description
    GridGroupingControl grid

    The GridGroupingControl that needs to be exported.

    System.String excelFileName

    The Excel file name.

    ExcelExportingOptions exportingOptions

    The ExcelExportingOptions

    Exceptions
    Type Condition
    System.ArgumentNullException

    If grid or excelFileName is null.

    System.ArgumentException

    If excelFileName length is equal to 0..

    GetGroupCaptionDisplayText(Group, String)

    Gets the caption text for a group.

    Declaration
    protected static string GetGroupCaptionDisplayText(Group group, string format)
    Parameters
    Type Name Description
    Group group

    The group to get caption text for.

    System.String format

    Caption format.

    Returns
    Type Description
    System.String

    Caption text for the group.

    GetGroupCaptionText(Group)

    Retrieves caption text for group.

    Declaration
    protected static string GetGroupCaptionText(Group group)
    Parameters
    Type Name Description
    Group group

    Group to get caption text from.

    Returns
    Type Description
    System.String

    Caption text.

    OnQueryExportCellRange(QueryExportCellRangeEventArgs)

    Used to trigger the ExportNestedTableEvent.

    Declaration
    protected void OnQueryExportCellRange(QueryExportCellRangeEventArgs e)
    Parameters
    Type Name Description
    QueryExportCellRangeEventArgs e

    The QueryExportCellRangeEventArgs.

    RaiseQueryExportCellRange(QueryExportCellRangeEventArgs)

    Used to raise the ExportNestedTableEvent.

    Declaration
    protected void RaiseQueryExportCellRange(QueryExportCellRangeEventArgs e)
    Parameters
    Type Name Description
    QueryExportCellRangeEventArgs e

    The QueryExportCellRangeEventArgs.

    Events

    QueryExportCellRange

    Occurs whenever cell range is exported.

    Declaration
    public event GridGroupingExcelConverterControl.QueryExportCellRangeEventHandler QueryExportCellRange
    Event Type
    Type Description
    GridGroupingExcelConverterControl.QueryExportCellRangeEventHandler

    QueryExportNestedTable

    Occurs whenever nested table is exported.

    Declaration
    public event GridGroupingExcelConverterControl.ExportNestedTableEventHandler QueryExportNestedTable
    Event Type
    Type Description
    GridGroupingExcelConverterControl.ExportNestedTableEventHandler

    QueryExportRowRange

    Occurs whenever row element is exported.

    Declaration
    public event GridGroupingExcelConverterControl.QueryExportRowRangeEventHandler QueryExportRowRange
    Event Type
    Type Description
    GridGroupingExcelConverterControl.QueryExportRowRangeEventHandler
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved