跳到主要内容

afterSelectionSet

描述

在单元格被选中后触发

用法

afterSelectionSet: (cell: string) => void;

参数

事件的回调函数接受以下参数:

  • cell - (必填)单元格的 id(可为多个)

示例

const spreadsheet = new dhx.Spreadsheet("spreadsheet", {});
spreadsheet.parse(data);

// 订阅 "afterSelectionSet" 事件
spreadsheet.events.on("afterSelectionSet", function(cell){
console.log("The cells " + spreadsheet.selection.getSelectedCell() + " are selected");
console.log(cell);
});

相关文章: 事件处理