ig.excel.WorksheetMergedCellsRegion

Represents a merged region of cells, or cells which share a value and format and appear as one cell when viewed in Microsoft Excel.

Remarks

Merged cell regions cannot overlap (a cell can only belong to one merged cell region). In addition, ArrayFormula and WorksheetDataTable instances cannot be applied to merged cell regions.

Dependencies

jquery-1.4.4.js
infragistics.util.js
infragistics.ext_core.js
infragistics.ext_collections.js
infragistics.ext_collectionsExtended.js
infragistics.ext_io.js
infragistics.ext_text.js
infragistics.documents.core_core.js
infragistics.ext_ui.js
The current widget has no options.
The current widget has no events.
  • applyArrayFormula
    Inherited

    .applyArrayFormula( value:string );

    Applies a array formula to the region of cells.

    • value
    • Type:string
    • The array formula to parse and apply to the region.

    Exceptions

    Exception Description
    ig.ArgumentNullException value is null or empty.
    ig.excel.FormulaParseException value is not a valid formula.
    ig.InvalidOperationException The region contains another array formula or data table which extends outside the region.

    Remarks

    value is parsed based on the CellReferenceMode of the Workbook to which the region belongs. If the region's WorksheetRegion.worksheet has been removed from its parent collection, the A1 CellReferenceMode will be used to parse the formula.

  • applyFormula
    Inherited

    .applyFormula( value:string );

    Applies a formula to the region of cells.

    • value
    • Type:string
    • The formula to parse and apply to the region.

    Exceptions

    Exception Description
    ig.ArgumentNullException value is null or empty.
    ig.excel.FormulaParseException value is not a valid formula.
    ig.InvalidOperationException The region contains an array formula or data table which extends outside the region.

    Remarks

    value is parsed based on the CellReferenceMode of the Workbook to which the region belongs. If the region's WorksheetRegion.worksheet has been removed from its parent collection, the A1 CellReferenceMode will be used to parse the formula.

    See Also

  • cellFormat

    .cellFormat( );
    Return Type:
    ig.excel.IWorksheetCellFormat
    Return Type Description:
    The cell formatting for the merged cell region.

    Gets the cell formatting for the merged cell region.

  • comment

    .comment( );
    Return Type:
    ig.excel.WorksheetCellComment
    Return Type Description:
    The comment for the merged cells region.

    Gets the comment for the merged cells region.

    Remarks

    The comment of the merged region can also be accessed from the top-left cell of the merged region of cells.

  • comment

    .comment( value:ig.excel.WorksheetCellComment );
    Return Type:
    ig.excel.WorksheetCellComment
    Return Type Description:
    The comment for the merged cells region.

    Sets the comment for the merged cells region.

    • value
    • Type:ig.excel.WorksheetCellComment

    Remarks

    The comment of the merged region can also be accessed from the top-left cell of the merged region of cells.

  • equals
    Inherited

    .equals( obj:object );

    Determines whether the specified value equals this WorksheetRegion.

    • obj
    • Type:object
    • The value to test for equality.
  • firstColumn
    Inherited

    .firstColumn( );
    Return Type:
    number
    Return Type Description:
    The index of the first column in the region.

    Gets the index of the first column in the region.

  • firstRow
    Inherited

    .firstRow( );
    Return Type:
    number
    Return Type Description:
    The index of the first row in the region.

    Gets the index of the first row in the region.

  • formatAsTable
    Inherited

    .formatAsTable( tableHasHeaders:boolean );
    Return Type:
    ig.excel.WorksheetTable
    Return Type Description:
    The WorksheetTable created the represent the formatted table for the region.

    Formats the region as a table and adds an associated WorksheetTable to the Worksheet.tables collection.

    • tableHasHeaders
    • Type:boolean
    • A value which indicates whether the top row of the region contains the headers for the table.

    Exceptions

    Exception Description
    ig.InvalidOperationException The region contains one or more cells from another WorksheetTable.
    ig.InvalidOperationException The region contains one or more cells which have a multi-cell ArrayFormula applied.
    ig.InvalidOperationException The region contains one or more cells which are part of a WorksheetDataTable.

    Remarks

    When the table is created, the Workbook.defaultTableStyle will be applied to the value.

    When the table is created, the column names will be taken from the cells in the header row if tableHasHeaders is True. If it is False, the column names will be generated and the cells for the header row will be inserted into the worksheet.

    The column names are unique within the owning WorksheetTable. If, when the table is created, there are two or more columns with the same name, the second and subsequent duplicate column names will have a number appended to make them unique. If any cells in the header row have a non-string value, their value will be changed to a string (the current display text of the cell). If any cells in the header row have no value, they will be given a generated column name.

    If the region partially contains any merged cell regions, they will be removed from the worksheet and the table region will be expanded to include all cells from the merged region.

  • formatAsTable
    Inherited

    .formatAsTable( tableHasHeaders:boolean, tableStyle:ig.excel.WorksheetTableStyle );
    Return Type:
    ig.excel.WorksheetTable
    Return Type Description:
    The WorksheetTable created the represent the formatted table for the region.

    Formats the region as a table and adds an associated WorksheetTable to the Worksheet.tables collection.

    • tableHasHeaders
    • Type:boolean
    • A value which indicates whether the top row of the region contains the headers for the table.
    • tableStyle
    • Type:ig.excel.WorksheetTableStyle
    • The WorksheetTableStyle to apply to the table or null to use the Workbook.defaultTableStyle.

    Exceptions

    Exception Description
    ig.ArgumentException The specified tableStyle does not exist in the Workbook.customTableStyles or Workbook.standardTableStyles collections.
    ig.InvalidOperationException The region contains one or more cells from another WorksheetTable.
    ig.InvalidOperationException The region contains one or more cells which have a multi-cell ArrayFormula applied.
    ig.InvalidOperationException The region contains one or more cells which are part of a WorksheetDataTable.

    Remarks

    When the table is created, the specified tableStyle will be applied to the value.

    When the table is created, the column names will be taken from the cells in the header row if tableHasHeaders is True. If it is False, the column names will be generated and the cells for the header row will be inserted into the worksheet.

    The column names are unique within the owning WorksheetTable. If, when the table is created, there are two or more columns with the same name, the second and subsequent duplicate column names will have a number appended to make them unique. If any cells in the header row have a non-string value, their value will be changed to a string (the current display text of the cell). If any cells in the header row have no value, they will be given a generated column name.

    If the region partially contains any merged cell regions, they will be removed from the worksheet and the table region will be expanded to include all cells from the merged region.

  • formula

    .formula( );
    Return Type:
    ig.excel.Formula
    Return Type Description:
    The formula which has been applied to the merged region or null if no formula has been applied.

    Gets the formula which has been applied to the merged region.

    See Also

  • getBoundsInTwips
    Inherited

    .getBoundsInTwips( );
    Return Type:
    object
    Return Type Description:
    The bounds of the region on its worksheet. This will be an object with numeric values for properties 'x', 'y', 'width', 'height', 'left', 'top', 'right', and 'bottom'.

    Gets the bounds of the region in twips (1/20th of a point).

    Remarks

    The bounds returned by this method are only valid with the current configuration of the worksheet. If any rows or columns before the region are resized, these bounds will no longer reflect the position of the region.

  • getBoundsInTwips
    Inherited

    .getBoundsInTwips( options:ig.excel.PositioningOptions );
    Return Type:
    object
    Return Type Description:
    The bounds of the region on its worksheet. This will be an object with numeric values for properties 'x', 'y', 'width', 'height', 'left', 'top', 'right', and 'bottom'.

    Gets the bounds of the region in twips (1/20th of a point).

    • options
    • Type:ig.excel.PositioningOptions
    • The options to use when getting the bounds of the region.

    Remarks

    The bounds returned by this method are only valid with the current configuration of the worksheet. If any rows or columns before the region are resized, these bounds will no longer reflect the position of the region.

  • getHashCode
    Inherited

    .getHashCode( );

    Gtes the hash code for the WorksheetRegion.

  • getResolvedCellFormat

    .getResolvedCellFormat( );
    Return Type:
    ig.excel.IWorksheetCellFormat
    Return Type Description:
    A format object describing the actual formatting that will be used when displayed this cell in Microsoft Excel.

    Gets the resolved cell formatting for this merged cell region.

    Remarks

    If any cell format properties are the default values on the merged cell region, the values from the owning row's cell format will be used. If those are default, then the values from the owning column's cell format will be used. Otherwise, the workbook default values will be used.

  • lastColumn
    Inherited

    .lastColumn( );
    Return Type:
    number
    Return Type Description:
    The index of the last column in the region.

    Gets the index of the last column in the region.

  • lastRow
    Inherited

    .lastRow( );
    Return Type:
    number
    Return Type Description:
    The index of the last row in the region.

    Gets the index of the last row in the region.

  • toString
    Inherited

    .toString( );
    Return Type:
    string
    Return Type Description:
    The string representation of the range of cells in the region.

    Gets the string representation of the range of cells in the region.

  • toString
    Inherited

    .toString( cellReferenceMode:ig.excel.CellReferenceMode, includeWorksheetName:boolean );
    Return Type:
    string
    Return Type Description:
    The string representation of the range of cells in the region.

    Gets the string representation of the range of cells in the region.

    • cellReferenceMode
    • Type:ig.excel.CellReferenceMode
    • The mode used to generate cell references.
    • includeWorksheetName
    • Type:boolean
    • The value indicating whether to include the worksheet name in the range address.
  • toString
    Inherited

    .toString( cellReferenceMode:ig.excel.CellReferenceMode, includeWorksheetName:boolean, useRelativeColumn:boolean, useRelativeRow:boolean );
    Return Type:
    string
    Return Type Description:
    The string representation of the range of cells in the region.

    Gets the string representation of the range of cells in the region.

    • cellReferenceMode
    • Type:ig.excel.CellReferenceMode
    • The mode used to generate cell references.
    • includeWorksheetName
    • Type:boolean
    • The value indicating whether to include the worksheet name in the range address.
    • useRelativeColumn
    • Type:boolean
    • The value indicating whether to use a relative column address for the cells in the range.
    • useRelativeRow
    • Type:boolean
    • The value indicating whether to use a relative row address for the cells in the range.
  • value

    .value( );
    Return Type:
    object
    Return Type Description:
    The value of the merged cell region.

    Gets the value of the merged cell region.

    Exceptions

    Exception Description
    ig.Error The assigned value's type is not supported and can't be exported to Excel.
    ig.InvalidOperationException The value assigned is a WorksheetMergedCellsRegion.formula. Instead, Formula.applyTo should be called on the Formula, passing in the cell.
    ig.InvalidOperationException The value assigned is a WorksheetDataTable. Instead, the WorksheetDataTable.cellsInTable should be set to a region containing the cell.
    ig.InvalidOperationException The value assigned is a FormattedString which is the value another cell or merged cell region.
    ig.InvalidOperationException The value is assigned and this cell is part of an ArrayFormula or WorksheetDataTable.

    Remarks

    The types supported for the value are:

    • System.Byte
    • System.SByte
    • System.Int16
    • System.Int64
    • System.UInt16
    • System.UInt64
    • System.UInt32
    • System.Int32
    • System.Single
    • System.Double
    • System.Boolean
    • System.Char
    • System.Enum
    • System.Decimal
    • System.DateTime
    • System.String
    • System.Text.StringBuilder
    • System.DBNull
    • ErrorValue
    • FormattedString

  • value

    .value( value:object );
    Return Type:
    object
    Return Type Description:
    The value of the merged cell region.

    Sets the value of the merged cell region.

    • value
    • Type:object

    Exceptions

    Exception Description
    ig.Error The assigned value's type is not supported and can't be exported to Excel.
    ig.InvalidOperationException The value assigned is a WorksheetMergedCellsRegion.formula. Instead, Formula.applyTo should be called on the Formula, passing in the cell.
    ig.InvalidOperationException The value assigned is a WorksheetDataTable. Instead, the WorksheetDataTable.cellsInTable should be set to a region containing the cell.
    ig.InvalidOperationException The value assigned is a FormattedString which is the value another cell or merged cell region.
    ig.InvalidOperationException The value is assigned and this cell is part of an ArrayFormula or WorksheetDataTable.

    Remarks

    The types supported for the value are:

    • System.Byte
    • System.SByte
    • System.Int16
    • System.Int64
    • System.UInt16
    • System.UInt64
    • System.UInt32
    • System.Int32
    • System.Single
    • System.Double
    • System.Boolean
    • System.Char
    • System.Enum
    • System.Decimal
    • System.DateTime
    • System.String
    • System.Text.StringBuilder
    • System.DBNull
    • ErrorValue
    • FormattedString

  • worksheet
    Inherited

    .worksheet( );
    Return Type:
    ig.excel.Worksheet
    Return Type Description:
    The worksheet on which the region resides or null if the region has been shifted off the worksheet.

    Gets the worksheet on which the region resides.

Copyright © 1996 - 2024 Infragistics, Inc. All rights reserved.