您好!经调研,了解到切换sheet时涉及到sheet的选择状态,在阻隔切换动作时,需要一并阻截sheet的选择状态变更情况,请参考如下代码:
- spread.bind(GC.Spread.Sheets.Events.ActiveSheetChanging, function (sender, args) {
- console.log('active sheet changing, args: ', args);
- args.newSheet.isSelected(false);
- args.oldSheet.isSelected(true);
- args.cancel = true;
- });
复制代码 |