ValueChanged监测不到下拉菜单选择的值呀,代码如下,下拉菜单选择完后没有触发ValueChanged方法- const test = (spread)=>{
- let sheet = spread.getSheet(0);
- let style = new GC.Spread.Sheets.Style();
- style.locked = false;
- style.cellButtons = [
- {
- imageType: GC.Spread.Sheets.ButtonImageType.dropdown,
- command: 'openList',
- useButtonStyle: false,
- },
- ];
- style.dropDowns = [
- {
- type: GC.Spread.Sheets.DropDownType.list,
- option: {
- // multiSelect: true,
- items: [
- {text: '1', value: '1'},
- {text: '2', value: '2'},
- {text: '3', value: '3'}
- ]
- },
- submitCommand: (activeSheet, value, option) => {
- activeSheet.getCell(option.row, option.col).text(value);
- },
- },
- ];
- sheet.setStyle(3,1,style);
- sheet.bind(GC.Spread.Sheets.Events.ValueChanged, function (e, args) {
- debugger;
- })
- }
复制代码 |