还有一个问题
const activesheet = spread.getSheetFromName('现有店铺信息')
let style = new GC.Spread.Sheets.Style();
style.backColor = "pink";
let cell = new GC.Spread.Sheets.ConditionalFormatting.NormalConditionRule();
cell.ruleType(GC.Spread.Sheets.ConditionalFormatting.RuleType.dateOccurringRule)
cell.ranges([new GC.Spread.Sheets.Range(1,12,activesheet.getRowCount(),3)])
cell.operator(GC.Spread.Sheets.ConditionalFormatting.ComparisonOperators.notBetween)
cell.value1(new Date(2021, 1, 1))
cell.value2(new Date(2022, 1, 1))
cell.style(style);
activesheet.conditionalFormats.addRule(cell);
spread.resumePaint()
spread.resumeEvent();
spread.resumeCalcService(true)
我这样写一个日期的条件格式 2021-2022之外报错 为啥不生效呢 |