Search results

SpreadsheetComponent

ejs-spreadsheet represents the VueJS Spreadsheet Component.

<ejs-spreadsheet></ejs-spreadsheet>

Properties

activeSheetIndex

number

Specifies active sheet index in workbook.

<div id='Spreadsheet'></div>
new Spreadsheet({
     activeSheetIndex: 2
...
 }, '#Spreadsheet');

Defaults to 0

allowCellFormatting

boolean

It allows you to apply styles (font size, font weight, font family, fill color, and more) to the spreadsheet cells.

Defaults to true

allowChart

boolean

It allows you to insert the chart in spreadsheet.

Defaults to true

allowConditionalFormat

boolean

It allows you to apply conditional formatting to the sheet.

Defaults to true

allowDataValidation

boolean

It allows you to apply validation to the spreadsheet cells.

Defaults to true

allowDelete

boolean

It allows you to delete rows, columns and sheets from spreadsheet.

Defaults to true

allowEditing

boolean

It allows you to add new data or update existing cell data. If it is false, it will act as read only mode.

Defaults to true

allowFiltering

boolean

It allows to enable/disable filter and its functionalities.

Defaults to true

allowFindAndReplace

boolean

It allows to enable/disable find & replace with its functionalities.

Defaults to true

It allows to enable/disable Hyperlink and its functionalities.

Defaults to true

allowImage

boolean

It allows you to insert the image in spreadsheet.

Defaults to true

allowInsert

boolean

It allows you to insert rows, columns and sheets in to the spreadsheet.

Defaults to true

allowMerge

boolean

It allows you to merge the range of cells.

Defaults to true

allowNumberFormatting

boolean

It allows formatting a raw number into different types of formats (number, currency, accounting, percentage, short date, long date, time, fraction, scientific, and text) with built-in format codes.

Defaults to true

allowOpen

boolean

It allows you to open an Excel file (.xlsx, .xls, and .csv) in Spreadsheet.

Defaults to true

allowResizing

boolean

If allowResizing is set to true, spreadsheet columns and rows can be resized.

Defaults to true

allowSave

boolean

It allows you to save Spreadsheet with all data as Excel file (.xlsx, .xls, and .csv).

Defaults to true

allowScrolling

boolean

It specifies whether the Spreadsheet should be rendered with scrolling or not. To customize the Spreadsheet scrolling behavior, use the scrollSettings property.

Defaults to true

allowSorting

boolean

It allows to enable/disable sort and its functionalities.

Defaults to true

allowUndoRedo

boolean

It allows to enable/disable undo and redo functionalities.

Defaults to true

allowWrap

boolean

It allows to enable/disable wrap text feature. By using this feature the wrapping applied cell text can wrap to the next line, if the text width exceeds the column width.

Defaults to true

cellStyle

CellStyleModel

Specifies the cell style options.

<div id='Spreadsheet'></div>
new Spreadsheet({
     ...
         cellStyle: { fontWeight: 'bold', fontSize: 12,
             fontStyle: 'italic', textIndent: '2pt'
             backgroundColor: '#4b5366', color: '#ffffff'
     },
     ...
 }, '#Spreadsheet');

Defaults to {}

cssClass

string

To specify a CSS class or multiple CSS class separated by a space, add it in the Spreadsheet root element. This allows you to customize the appearance of component.

<div id='spreadsheet'></div>
new Spreadsheet({
 cssClass: 'e-custom1 e-custom2',
 ...
}, '#spreadsheet');

Defaults to

definedNames

DefineNameModel[]

Specifies the name for a range and uses it in formula for calculation.

<div id='Spreadsheet'></div>
new Spreadsheet({
     ...
     definedNames: [{ name: 'namedRange1', refersTo: 'Sheet1!A1:B5' }],
     ...
 }, '#Spreadsheet');

Defaults to []

enableClipboard

boolean

It enables or disables the clipboard operations (cut, copy, and paste) of the Spreadsheet.

Defaults to true

enableContextMenu

boolean

It enables or disables the context menu option of spreadsheet. By default, context menu will opens for row header, column header, sheet tabs, and cell.

Defaults to true

enableKeyboardNavigation

boolean

It allows you to interact with cell, sheet tabs, formula bar, and ribbon through the keyboard device.

Defaults to true

enableKeyboardShortcut

boolean

It enables shortcut keys to perform Spreadsheet operations like open, save, copy, paste, and more.

Defaults to true

enablePersistence

boolean

Enable or disable persisting component’s state between page reloads.

Defaults to false

enableRtl

boolean

Enable or disable rendering component in right to left direction.

Defaults to false

height

string | number

Defines the height of the Spreadsheet. It accepts height as pixels, number, and percentage.

<div id='Spreadsheet'></div>
new Spreadsheet({
     height: '550px'
...
 }, '#Spreadsheet');

Defaults to ‘100%’

isProtected

boolean

Specifies to protect the workbook.

Defaults to false

locale

string

Overrides the global culture and localization value for this component. Default global culture is ‘en-US’.

Defaults to

openUrl

string

Specifies the service URL to open excel file in spreadsheet.

Defaults to

password

string

Specifies the password.

Defaults to

saveUrl

string

Specifies the service URL to save spreadsheet as Excel file.

Defaults to

scrollSettings

ScrollSettingsModel

Configures the scroll settings.

<div id='Spreadsheet'></div>
new Spreadsheet({
     scrollSettings: {
         isFinite: true,
         enableVirtualization: false
     }
...
 }, '#Spreadsheet');

The allowScrolling property should be true.

Defaults to { isFinite: false, enableVirtualization: true }

selectionSettings

SelectionSettingsModel

Configures the selection settings.

<div id='Spreadsheet'></div>
new Spreadsheet({
     selectionSettings: {
         mode: 'None'
     }
...
}, '#Spreadsheet');
The selectionSettings `mode` property has three values and it is described below:

* None: Disables UI selection.
* Single: Allows single selection of cell, row, or column and disables multiple selection.
* Multiple: Allows multiple selection of cell, row, or column and disables single selection.

Defaults to { mode: ‘Multiple’ }

sheets

SheetModel[]

Configures sheets and its options.

<div id='Spreadsheet'></div>
new Spreadsheet({
     sheets: [{
                 name: 'First Sheet',
                 range: [{ dataSource: data }],
                 rows: [{
                         index: 5,
                         cells: [{ index: 4, value: 'Total Amount:' },
                                 { formula: '=SUM(F2:F30)', style: { fontWeight: 'bold' } }]
                 }]
             }, {
                 name: 'Second Sheet',
                 columns: [{ width: 180 }, { index: 4, width: 130 }]
             }]
...
 }, '#Spreadsheet');

Defaults to []

showFormulaBar

boolean

It shows or hides the formula bar and its features.

Defaults to true

showRibbon

boolean

It shows or hides the ribbon in spreadsheet.

Defaults to true

showSheetTabs

boolean

It shows or hides the sheets tabs, this is used to navigate among the sheets and create or delete sheets by UI interaction.

Defaults to true

width

string | number

Defines the width of the Spreadsheet. It accepts width as pixels, number, and percentage.

<div id='Spreadsheet'></div>
new Spreadsheet({
     width: '550px'
...
 }, '#Spreadsheet');

Defaults to ‘100%’

Methods

Unfreeze

This method is used to unfreeze the frozen rows and columns from the active sheet.

Parameter Type Description
sheet (optional) number | string Specifies the sheet name or index in which the unfreeze operation will perform. By default,
active sheet will be considered.

Returns void

addContextMenuItems

To add context menu items.

Parameter Type Description
items MenuItemModel[] Items that needs to be added.
text string Item before / after that the element to be inserted.
insertAfter (optional) boolean Set false if the items need to be inserted before the text.
By default, items are added after the text.
isUniqueId (optional) boolean Set true if the given text is a unique id.

Returns void

addCustomFunction

To add custom library function.

Parameter Type Description
functionHandler string | Function Custom function handler name
functionName (optional) string Custom function name

Returns void

addDataValidation

This method is used to add data validation.

Parameter Type Description
rules ValidationModel specifies the validation rules like type, operator, value1, value2, ignoreBlank, inCellDropDown, isHighlighted arguments.
range (optional) string range that needs to be add validation.

Returns void

addDefinedName

Adds the defined name to the Spreadsheet.

Parameter Type Description
definedName DefineNameModel Specifies the name, scope, comment, refersTo.

Returns boolean

addFileMenuItems

To add custom file menu items.

Parameter Type Description
items MenuItemModel[] Specifies the ribbon file menu items to be inserted.
text string Specifies the existing file menu item text before / after which the new file menu items to be inserted.
insertAfter (optional) boolean Set false if the items need to be inserted before the text.
By default, items are added after the text.
isUniqueId (optional) boolean Set true if the given file menu items text is a unique id.

Returns void

To add the hyperlink in the cell

Parameter Type Description
hyperlink string | HyperlinkModel to specify the hyperlink
address string to specify the address

Returns void

addInvalidHighlight

This method is used to highlight the invalid data.

Parameter Type Description
range (optional) string range that needs to be highlight the invalid data.

Returns void

addRibbonTabs

To add custom ribbon tabs.

Parameter Type Description
items RibbonItemModel[] Specifies the ribbon tab items to be inserted.
insertBefore (optional) string Specifies the existing ribbon header text before which the new tabs will be inserted.
If not specified, the new tabs will be inserted at the end.

Returns void

addToolbarItems

To add the custom items in Spreadsheet ribbon toolbar.

Parameter Type Description
tab string Specifies the ribbon tab header text under which the specified items will be inserted.
items ItemModel[] Specifies the ribbon toolbar items that needs to be inserted.
index (optional) number Specifies the index text before which the new items will be inserted.
If not specified, the new items will be inserted at the end of the toolbar.

Returns void

appendTo

Appends the control within the given HTML Div element.

Parameter Type Description
selector string | HTMLElement Target element where control needs to be appended.

Returns void

applyFilter

Applies the filter UI in the range of cells in the sheet.

Parameter Type Description
predicates (optional) PredicateModel[] Specifies the predicates.
range (optional) string Specify the range.

Returns void

autoFit

This method is used to autofit the range of rows or columns

Parameter Type Description
range string range of rows or columns that needs to be autofit.

Returns void

cellFormat

Applies the style (font family, font weight, background color, etc…) to the specified range of cells.

Parameter Type Description
style CellStyleModel Specifies the cell style.
range (optional) string Specifies the address for the range of cells.

Returns void

clear

This method is used to Clear contents, formats and hyperlinks in spreadsheet.

Parameter Type Description
options ClearOptions Options for clearing the content, formats and hyperlinks in spreadsheet.

Returns void

clearConditionalFormat

This method is used for remove conditional formatting.

Parameter Type Description
range (optional) string range that needs to be remove conditional formatting.

Returns void

clearFilter

Clears the filter changes of the sheet.

Parameter Type Description
field (optional) string Specify the field.

Returns void

closeEdit

Cancels the edited state, this will not update any value in the cell.

Returns void

computeExpression

Used to compute the specified expression/formula.

Parameter Type Description
formula string Specifies the formula(=SUM(A1:A3)) or expression(2+3).

Returns string | number

conditionalFormat

This method is used to add conditional formatting.

Parameter Type Description
conditionalFormat ConditionalFormatModel Specify the conditionalFormat.

Returns void

copy

To copy the specified cell or cells properties such as value, format, style etc…

Parameter Type Description
address (optional) string Specifies the range address.

Returns Promise

cut

To cut the specified cell or cells properties such as value, format, style etc…

Parameter Type Description
address (optional) string Specifies the range address to cut.

Returns Promise

delete

Used to delete rows, columns and sheets from the spreadsheet.

Parameter Type Description
startIndex (optional) number Specifies the start sheet / row / column index.
endIndex (optional) number Specifies the end sheet / row / column index.
model (optional) string Specifies the delete model type. By default, the model is considered as Sheet. The possible values are,
- Row: To delete rows.
- Column: To delete columns.
- Sheet: To delete sheets.
sheet (optional) number | string Specifies the sheet name or index in which the delete operation will perform. By default,
active sheet will be considered. It is applicable only for model type Row and Column.

Returns void

deleteChart

Used to delete the chart from spreadsheet.

Parameter Type Description
id (optional) string Specifies the chart element id.

Returns void

deleteImage

Used to delete the image in spreadsheet.

Parameter Type Description
id string Specifies the id of the image element to be deleted.
range (optional) string Specifies the range in spreadsheet.

Returns void

destroy

Destroys the component (detaches/removes all event handlers, attributes, classes, and empties the component element).

Returns void

duplicateSheet

Used to make a duplicate/copy of the sheet in the spreadsheet.

Parameter Type Description
sheetIndex (optional) number Specifies the index of the sheet to be duplicated. By default, the active sheet will be duplicated.

Returns void

enableContextMenuItems

To enable / disable context menu items.

Parameter Type Description
items string[] Items that needs to be enabled / disabled.
enable (optional) boolean Set true / false to enable / disable the menu items.
isUniqueId (optional) boolean Set true if the given text is a unique id.

Returns void

enableFileMenuItems

To enable / disable file menu items.

Parameter Type Description
items string[] Items that needs to be enabled / disabled.
enable (optional) boolean Set true / false to enable / disable the menu items.
isUniqueId (optional) boolean Set true if the given file menu items text is a unique id.

Returns void

enableRibbonTabs

To enable / disable the existing ribbon tabs.

Parameter Type Description
tabs string[] Specifies the tab header text which needs to be enabled / disabled.
enable (optional) boolean Set true / false to enable / disable the ribbon tabs.

Returns void

enableToolbarItems

Enables or disables the specified ribbon toolbar items or all ribbon items.

Parameter Type Description
tab string Specifies the ribbon tab header text under which the toolbar items need to be enabled / disabled.
items (optional) number[] | string[] Specifies the toolbar item indexes / unique id’s which needs to be enabled / disabled.
If it is not specified the entire toolbar items will be enabled / disabled.
enable (optional) boolean Boolean value that determines whether the toolbar items should be enabled or disabled.

Returns void

endEdit

If Spreadsheet is in editable state, you can save the cell by invoking endEdit.

Returns void

find

To find the specified cell value.

Parameter Type Description
args FindOptions Specifies the replace value with find args to replace specified cell value.

Returns void

findAll

To Find All the Match values Address within Sheet or Workbook.

Parameter Type Description
value string Specifies the value to find.
mode (optional) string Specifies the value to be find within Sheet/Workbook.
isCSen (optional) boolean Specifies the find match with case sensitive or not.
isEMatch (optional) boolean Specifies the find match with entire match or not.
sheetIndex (optional) number Specifies the sheetIndex. If not specified, it will consider the active sheet.

Returns string[]

freezePanes

This method is used to freeze rows and columns after the specified cell in the Spreadsheet.

Parameter Type Description
row (optional) number Specifies the freezed row count.
column (optional) number Specifies the freezed column count.
sheet (optional) number | string Specifies the sheet name or index in which the freeze operation will perform. By default,
active sheet will be considered.

Returns void

getData

Gets the range of data as JSON from the specified address.

Parameter Type Description
address string Specifies the address for range of cells.

Returns Promise

getDisplayText

Gets the formatted text of the cell.

Parameter Type Description
cell CellModel Specifies the cell.

Returns string

getSelectAllContent

Get the select all div of spreadsheet

Returns HTMLElement

goTo

Used to navigate to cell address within workbook.

Parameter Type Description
address string Specifies the cell address you need to navigate.
You can specify the address in two formats,
{sheet name}!{cell address} - Switch to specified sheet and navigate to specified cell address.
{cell address} - Navigate to specified cell address with in the active sheet.

Returns void

hideFileMenuItems

To show/hide the file menu items in Spreadsheet ribbon.

Parameter Type Description
items string[] Specifies the file menu items text which is to be show/hide.
hide (optional) boolean Set true / false to hide / show the file menu items.
isUniqueId (optional) boolean Set true if the given file menu items text is a unique id.

Returns void

hideRibbonTabs

To show/hide the existing ribbon tabs.

Parameter Type Description
tabs string[] Specifies the tab header text which needs to be shown/hidden.
hide (optional) boolean Set true / false to hide / show the ribbon tabs.

Returns void

hideSpinner

To hide showed spinner manually.

Returns void

hideToolbarItems

To show/hide the existing Spreadsheet ribbon toolbar items.

Parameter Type Description
tab string Specifies the ribbon tab header text under which the specified items needs to be hidden / shown.
indexes number[] Specifies the toolbar indexes which needs to be shown/hidden from UI.
hide (optional) boolean Set true / false to hide / show the toolbar items.

Returns void

insertChart

Used to set the chart in spreadsheet.

Parameter Type Description
chart (optional) ChartModel[] Specifies the options to insert chart in spreadsheet.

Returns void

insertColumn

Used to insert columns in to the spreadsheet.

Parameter Type Description
startColumn (optional) number | ColumnModel[] Specifies the start column index / column model which needs to be inserted.
endColumn (optional) number Specifies the end column index.
sheet (optional) number | string Specifies the sheet name or index in which the insert operation will perform. By default,
active sheet will be considered.

Returns void

insertImage

Used to set the image in spreadsheet.

Parameter Type Description
images ImageModel[] Specifies the options to insert image in spreadsheet.
range (optional) string Specifies the range in spreadsheet.

Returns void

insertRow

Used to insert rows in to the spreadsheet.

Parameter Type Description
startRow (optional) number | RowModel[] Specifies the start row index / row model which needs to be inserted.
endRow (optional) number Specifies the end row index.
sheet (optional) number | string Specifies the sheet name or index in which the insert operation will perform. By default,
active sheet will be considered.

Returns void

insertSheet

Used to insert sheets in to the spreadsheet.

Parameter Type Description
startSheet (optional) number | SheetModel[] Specifies the start sheet index / sheet model which needs to be inserted.
endSheet (optional) number Specifies the end sheet index.

Returns void

lockCells

Applies cell lock to the specified range of cells.

Parameter Type Description
range (optional) string Specifies the address for the range of cells.
isLocked (optional) boolean -Specifies the cell is locked or not.

Returns void

merge

Used to merge the range of cells.

Parameter Type Description
range (optional) string Specifies the range of cells as address.
type (optional) string Specifies the merge type. The possible values are,
- All: Merge all the cells between provided range.
- Horizontally: Merge the cells row-wise.
- Vertically: Merge the cells column-wise.

Returns void

moveSheet

Used to move the sheets to the specified position in the list of sheets.

Parameter Type Description
position number Specifies the position to move a sheet in the list of sheets.
sheetIndexes (optional) number[] Specifies the indexes of the sheet to be moved. By default, the active sheet will be moved.

Returns void

numberFormat

Applies the number format (number, currency, percentage, short date, etc…) to the specified range of cells.

Parameter Type Description
format string Specifies the number format code.
range (optional) string Specifies the address for the range of cells.

Returns void

open

Opens the Excel file.

Parameter Type Description
options OpenOptions Options for opening the excel file.

Returns void

openFromJson

Opens the specified JSON object.

The available arguments in options are:

  • file: Specifies the spreadsheet model as object or string. And the object contains the jsonObject, which is saved from spreadsheet using saveAsJson method.
Parameter Type Description
options Object Options for opening the JSON object.

Returns void

paste

This method is used to paste the cut or copied cells in to specified address.

Parameter Type Description
address (optional) string Specifies the cell or range address.
type (optional) string Specifies the type of paste.

Returns void

protectSheet

To protect the particular sheet.

Parameter Type Description
sheet (optional) number | string Specifies the sheet to protect.
protectSettings (optional) ProtectSettingsModel Specifies the protect sheet options.

Returns void

redo

To perform the redo operation in spreadsheet.

Returns void

refresh

Used to refresh the spreadsheet in UI level.

Parameter Type Description
isNew (optional) boolean Specifies true / false to create new workbook in spreadsheet.

Returns void

removeContextMenuItems

To remove existing context menu items.

Parameter Type Description
items string[] Items that needs to be removed.
isUniqueId (optional) boolean Set true if the given text is a unique id.

Returns void

removeDataValidation

This method is used for remove validation.

Parameter Type Description
range (optional) string range that needs to be remove validation.

Returns void

removeDefinedName

Removes the defined name from the Spreadsheet.

Parameter Type Description
definedName string Specifies the name.
scope string Specifies the scope of the defined name.

Returns boolean

To remove the hyperlink in the cell

Parameter Type Description
range string To specify the range

Returns void

removeInvalidHighlight

This method is used for remove highlight from invalid data.

Parameter Type Description
range (optional) string range that needs to be remove invalid highlight.

Returns void

replace

To replace the specified cell value.

Parameter Type Description
args FindOptions Specifies the replace value with find args to replace specified cell value.

Returns void

resize

Used to resize the Spreadsheet.

Returns void

save

Saves the Spreadsheet data to Excel file.

The available arguments in saveOptions are:

  • url: Specifies the save URL.
  • fileName: Specifies the file name.
  • saveType: Specifies the file type need to be saved.
Parameter Type Description
saveOptions (optional) SaveOptions Options for saving the excel file.

Returns void

saveAsJson

Saves the Spreadsheet data as JSON object.

Returns Promise

selectRange

Selects the cell / range of cells with specified address.

Parameter Type Description
address string Specifies the range address.

Returns void

setBorder

Sets the border to specified range of cells.

Parameter Type Description
style CellStyleModel Specifies the style property which contains border value.
range (optional) string Specifies the range of cell reference. If not specified, it will considered the active cell reference.
type (optional) string Specifies the range of cell reference. If not specified, it will considered the active cell reference.

Returns void

setColWidth

Set the width of column.

Parameter Type Description
width (optional) number | string To specify the width
colIndex (optional) number To specify the colIndex
sheetIndex (optional) number To specify the sheetIndex

Returns void

setRowHeight

Set the height of row.

Parameter Type Description
height (optional) number | string Specifies height needs to be updated. If not specified, it will set the default height 20.
rowIndex (optional) number Specifies the row index. If not specified, it will consider the first row.
sheetIndex (optional) number Specifies the sheetIndex. If not specified, it will consider the active sheet.
edited (optional) boolean Specifies the boolean value.

Returns void

showSpinner

By default, Spreadsheet shows the spinner for all its actions. To manually show spinner you this method at your needed time.

Returns void

sort

Sorts the range of cells in the active sheet.

Parameter Type Description
sortOptions (optional) SortOptions options for sorting.
range (optional) string address of the data range.

Returns Promise

startEdit

Start edit the active cell.

Returns void

undo

To perform the undo operation in spreadsheet.

Returns void

unprotectSheet

To unprotect the particular sheet.

Parameter Type Description
sheet (optional) number | string Specifies the sheet name or index to Unprotect.

Returns void

updateAction

To update the action which need to perform.

Parameter Type Description
options CollaborativeEditArgs It describes an action and event args to perform.

Returns void

updateCell

To update a cell properties.

Parameter Type Description
cell CellModel Cell properties.
address (optional) string Address to update.

Returns void

updateUndoRedoCollection

To update the undo redo collection in spreadsheet.

Parameter Type Description
args Object options for undo redo.

Returns void

wrap

This method is used to wrap/unwrap the text content of the cell.

Parameter Type Description
address string Address of the cell to be wrapped.
wrap (optional) boolean Set false if the text content of the cell to be unwrapped.

Returns void

Events

actionBegin

EmitType<``BeforeCellFormatArgs|BeforeOpenEventArgs|BeforeSaveEventArgs|BeforeSelectEventArgs|BeforeSortEventArgs|CellEditEventArgs|MenuSelectEventArgs>

Triggers when the Spreadsheet actions (such as editing, formatting, sorting etc..) are starts.

<div id='Spreadsheet'></div>
new Spreadsheet({
      actionBegin: (args: BeforeCellFormatArgs|BeforeOpenEventArgs|BeforeSaveEventArgs|BeforeSelectEventArgs
                   |BeforeSortEventArgs|CellEditEventArgs|MenuSelectEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

actionComplete

EmitType<CellSaveEventArgs>|SaveCompleteEventArgs|Object

Triggers when the spreadsheet actions (such as editing, formatting, sorting etc..) gets completed.

<div id='Spreadsheet'></div>
new Spreadsheet({
      actionComplete: (args: SortEventArgs|CellSaveEventArgs|SaveCompleteEventArgs|Object) => {
      }
     ...
 }, '#Spreadsheet');

afterHyperlinkClick

EmitType<AfterHyperlinkArgs>

Triggers when the Hyperlink function gets completed.

<div id='Spreadsheet'></div>
new Spreadsheet({
      afterHyperlinkClick: (args: AfterHyperlinkArgs ) => {
      }
     ...
 }, '#Spreadsheet');

afterHyperlinkCreate

EmitType<AfterHyperlinkArgs>

Triggers after the hyperlink inserted.

<div id='Spreadsheet'></div>
new Spreadsheet({
      afterHyperlinkCreate: (args: afterHyperlinkArgs ) => {
      }
     ...
 }, '#Spreadsheet');

beforeCellFormat

EmitType<BeforeCellFormatArgs>

Triggers before the cell format applied to the cell.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeCellFormat: (args: BeforeCellFormatArgs) => {
      }
     ...
 }, '#Spreadsheet');

beforeCellRender

EmitType<CellRenderEventArgs>

Triggers before the cell appended to the DOM.

<div id='Spreadsheet'></div>
new Spreadsheet({
     beforeCellRender: (args: CellRenderEventArgs) => {
     }
     ...
 }, '#Spreadsheet');

beforeCellSave

EmitType<CellEditEventArgs>

Triggers when before the cell is saved.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeCellSave: (args: CellEditEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

beforeConditionalFormat

EmitType<ConditionalFormatEventArgs>

Triggers before apply or remove the conditional format from a cell in a range.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeConditionalFormat: (args: ConditionalFormatEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

beforeDataBound

EmitType<Object>

Triggers before the data is populated to the worksheet.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeDataBound: (args: Object) => {
      }
     ...
 }, '#Spreadsheet');

beforeHyperlinkClick

EmitType<BeforeHyperlinkArgs>

Triggers when the Hyperlink is clicked.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeHyperlinkClick: (args: BeforeHyperlinkArgs ) => {
      }
     ...
 }, '#Spreadsheet');

beforeHyperlinkCreate

EmitType<BeforeHyperlinkArgs>

Triggers before insert a hyperlink.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeHyperlinkCreate: (args: BeforeHyperlinkArgs ) => {
      }
     ...
 }, '#Spreadsheet');

beforeOpen

EmitType<BeforeOpenEventArgs>

Triggers before opening an Excel file.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeOpen: (args: BeforeOpenEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

beforeSave

EmitType<BeforeSaveEventArgs>

Triggers before saving the Spreadsheet as Excel file.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeSave: (args: BeforeSaveEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

beforeSelect

EmitType<BeforeSelectEventArgs>

Triggers before the cell or range of cells being selected.

<div id='Spreadsheet'></div>
new Spreadsheet({
     beforeSelect: (args: BeforeSelectEventArgs) => {
     }
     ...
 }, '#Spreadsheet');

beforeSort

EmitType<BeforeSortEventArgs>

Triggers before sorting the specified range.

<div id='Spreadsheet'></div>
new Spreadsheet({
      beforeSort: (args: BeforeSortEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

cellEdit

EmitType<CellEditEventArgs>

Triggers when the cell is being edited.

<div id='Spreadsheet'></div>
new Spreadsheet({
      cellEdit: (args: CellEditEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

cellEditing

EmitType<CellEditEventArgs>

Triggers every time a request is made to access cell information. This will be triggered when editing a cell.

<div id='Spreadsheet'></div>
new Spreadsheet({
      cellEditing: (args: CellEditEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

cellSave

EmitType<CellSaveEventArgs>

Triggers when the edited cell is saved.

<div id='Spreadsheet'></div>
new Spreadsheet({
      cellSave: (args: CellSaveEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

contextMenuBeforeClose

EmitType<BeforeOpenCloseMenuEventArgs>

Triggers before closing the context menu.

<div id='Spreadsheet'></div>
new Spreadsheet({
      contextMenuBeforeClose: (args: BeforeOpenCloseMenuEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

contextMenuBeforeOpen

EmitType<BeforeOpenCloseMenuEventArgs>

Triggers before opening the context menu and it allows customizing the menu items.

<div id='Spreadsheet'></div>
new Spreadsheet({
      contextMenuBeforeOpen: (args: BeforeOpenCloseMenuEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

contextMenuItemSelect

EmitType<MenuSelectEventArgs>

Triggers when the context menu item is selected.

<div id='Spreadsheet'></div>
new Spreadsheet({
      contextMenuItemSelect: (args: MenuSelectEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

created

EmitType<Event>

Triggers when the component is created.

<div id='Spreadsheet'></div>
new Spreadsheet({
      created: () => {
      }
     ...
 }, '#Spreadsheet');

dataBound

EmitType<Object>

Triggers when the data is populated in the worksheet.

<div id='Spreadsheet'></div>
new Spreadsheet({
      dataBound: (args: Object) => {
      }
     ...
 }, '#Spreadsheet');

dataSourceChanged

EmitType<DataSourceChangedEventArgs>

Triggers during data changes when the data is provided as dataSource in the Spreadsheet.

<div id='Spreadsheet'></div>
new Spreadsheet({
      dataSourceChanged: (args: DataSourceChangedEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

dialogBeforeOpen

EmitType<DialogBeforeOpenEventArgs>

Triggers before opening the dialog box.

<div id='Spreadsheet'></div>
new Spreadsheet({
      dialogBeforeOpen: (args: DialogBeforeOpenEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

fileMenuBeforeClose

EmitType<BeforeOpenCloseMenuEventArgs>

Triggers before closing the file menu.

<div id='Spreadsheet'></div>
new Spreadsheet({
      fileMenuBeforeClose: (args: BeforeOpenCloseMenuEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

fileMenuBeforeOpen

EmitType<BeforeOpenCloseMenuEventArgs>

Triggers before opening the file menu.

<div id='Spreadsheet'></div>
new Spreadsheet({
      fileMenuBeforeOpen: (args: BeforeOpenCloseMenuEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

fileMenuItemSelect

EmitType<MenuSelectEventArgs>

Triggers when the file menu item is selected.

<div id='Spreadsheet'></div>
new Spreadsheet({
      fileMenuItemSelect: (args: MenuSelectEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

openComplete

EmitType<Object>

Triggers when the spreadsheet importing gets completed.

<div id='Spreadsheet'></div>
new Spreadsheet({
      openComplete: (args: Object) => {
      }
     ...
 }, '#Spreadsheet');

openFailure

EmitType<OpenFailureArgs>

Triggers when the opened Excel file fails to load.

<div id='Spreadsheet'></div>
new Spreadsheet({
      openFailure: (args: OpenFailureArgs) => {
      }
     ...
 }, '#Spreadsheet');

queryCellInfo

EmitType<CellInfoEventArgs>

Triggered every time a request is made to access cell information.

<div id='Spreadsheet'></div>
new Spreadsheet({
     queryCellInfo: (args: CellInfoEventArgs) => {
     }
     ...
 }, '#Spreadsheet');

saveComplete

EmitType<SaveCompleteEventArgs>

Triggers after saving the Spreadsheet as Excel file.

<div id='Spreadsheet'></div>
new Spreadsheet({
      saveComplete: (args: SaveCompleteEventArgs) => {
      }
     ...
 }, '#Spreadsheet');

select

EmitType<SelectEventArgs>

Triggers after the cell or range of cells is selected.

<div id='Spreadsheet'></div>
new Spreadsheet({
     select: (args: SelectEventArgs) => {
     }
     ...
 }, '#Spreadsheet');

sortComplete

EmitType<SortEventArgs>

Triggers after sorting action is completed.

<div id='Spreadsheet'></div>
new Spreadsheet({
      sortComplete: (args: SortEventArgs) => {
      }
     ...
 }, '#Spreadsheet');
Contents
Contents