ASP.NET Core MVC Controls | ComponentOne
In This Topic
    FlexSheetPanel Class
    In This Topic
    File
    wijmo.grid.sheet.js
    Module
    wijmo.grid.sheet
    Base Class
    GridPanel

    Defines the extension of the GridPanel class, which is used by FlexSheet where the base FlexGrid class uses GridPanel. For example, the cells property returns an instance of this class.

    Constructor

    constructor

    constructor(grid: FlexGrid, cellType: CellType, rows: RowCollection, cols: ColumnCollection, element: HTMLElement): FlexSheetPanel
    

    Initializes a new instance of the FlexSheetPanel class.

    Parameters
    Returns
    FlexSheetPanel

    Properties

    activeCell

    Gets the active cell in this panel.

    Inherited From
    GridPanel
    Type
    HTMLElement

    cellType

    Gets the type of cell contained in the panel.

    Inherited From
    GridPanel
    Type
    CellType

    columns

    Gets the panel's column collection.

    Inherited From
    GridPanel
    Type
    ColumnCollection

    grid

    Gets the grid that owns the panel.

    Inherited From
    GridPanel
    Type
    FlexGrid

    height

    Gets the total height of the content in this panel.

    Inherited From
    GridPanel
    Type
    number

    hostElement

    Gets the host element for the panel.

    Inherited From
    GridPanel
    Type
    HTMLElement

    rows

    Gets the panel's row collection.

    Inherited From
    GridPanel
    Type
    RowCollection

    viewRange

    Gets a CellRange that indicates the range of cells currently visible on the panel.

    Inherited From
    GridPanel
    Type
    CellRange

    width

    Gets the total width of the content in the panel.

    Inherited From
    GridPanel
    Type
    number

    Methods

    getCellBoundingRect

    getCellBoundingRect(r: number, c: number | string, raw?: boolean): Rect
    

    Gets a cell's bounds in viewport coordinates.

    The returned value is a Rect object which contains the position and dimensions of the cell in viewport coordinates. The viewport coordinates are the same as those used by the getBoundingClientRect method.

    Parameters
    • r: number

      The index of the row that contains the cell.

    • c: number | string

      The index, name, or binding of the column that contains the cell.

    • raw: boolean Optional

      Whether to return the rectangle in raw panel coordinates as opposed to viewport coordinates.

    Inherited From
    GridPanel
    Returns
    Rect

    getCellData

    getCellData(r: number, c: any, formatted: boolean): any
    

    Gets the value stored in a cell in the panel.

    Parameters
    • r: number

      The row index of the cell.

    • c: any

      The index, name, or binding of the column that contains the cell.

    • formatted: boolean

      Whether to format the value for display.

    Returns
    any

    getCellElement

    getCellElement(r: number, c: number | string): HTMLElement
    

    Gets the element that represents a cell within this GridPanel.

    If the cell is not currently in view, this method returns null.

    Parameters
    • r: number

      The index of the row that contains the cell.

    • c: number | string

      The index, name, or binding of the column that contains the cell.

    Inherited From
    GridPanel
    Returns
    HTMLElement

    getLastVisibleColumn

    getLastVisibleColumn(end?: number): number
    

    Returns the last visible column present in the panel upto and including the end position. return -1 if no visible column is present

    Parameters
    • end: number Optional

      Last index of column to check.

    Inherited From
    GridPanel
    Returns
    number

    getLastVisibleRow

    getLastVisibleRow(end?: number): number
    

    Returns the last visible row present in the panel upto and including the end position. return -1 if no visible row is present

    Parameters
    • end: number Optional

      Last index of row to check.

    Inherited From
    GridPanel
    Returns
    number

    getNextVisibleColumn

    getNextVisibleColumn(start?: number): number
    

    Returns the next visible column present in the panel including the start position. return -1 if no visible column is present

    Parameters
    • start: number Optional

      Starting index of column.

    Inherited From
    GridPanel
    Returns
    number

    getNextVisibleRow

    getNextVisibleRow(start?: number): number
    

    Returns the next visible row present in the panel including the start position. return -1 if no visible row is present

    Parameters
    • start: number Optional

      Starting index of row.

    Inherited From
    GridPanel
    Returns
    number

    getSelectedState

    getSelectedState(r: number, c: number, rng: CellRange): SelectedState
    

    Gets a SelectedState value that indicates the selected state of a cell.

    Overrides this method to support multiple selection showSelectedHeaders for FlexSheet

    Parameters
    • r: number

      Row index of the cell to inspect.

    • c: number

      Column index of the cell to inspect.

    • rng: CellRange

      CellRange that contains the cell to inspect.

    Returns
    SelectedState

    isRangeValid

    isRangeValid(rng: CellRange): boolean
    

    Checks whether a given CellRange is valid for this panel's row and column collections.

    Parameters
    Inherited From
    GridPanel
    Returns
    boolean

    setCellData

    setCellData(r: number, c: any, value: any, coerce?: boolean, invalidate?: boolean, isMapKeyValue?: boolean): boolean
    

    Sets the content of a cell in the panel.

    Parameters
    • r: number

      The index of the row that contains the cell.

    • c: any

      The index, name, or binding of the column that contains the cell.

    • value: any

      The value to store in the cell.

    • coerce: boolean Optional

      A value indicating whether to change the value automatically to match the column's data type.

    • invalidate: boolean Optional

      Whether to invalidate the FlexSheet to show the change.

    • isMapKeyValue: boolean Optional

      value passed is already key value of dataMap, don't need re-find.

    Returns
    boolean