关于2我这边现在发现可以这样实现,你看看是否有涉及你说的bug
- var iconSetRule = new GC.Spread.Sheets.ConditionalFormatting.IconSetRule();
- iconSetRule.ranges([new GC.Spread.Sheets.Range(0, 0, 4, 1)]);
- iconSetRule.iconSetType(
- GC.Spread.Sheets.ConditionalFormatting.IconSetType.threeTriangles
- );
- var icons = iconSetRule.icons();
- icons[0] = {
- iconSetType:
- GC.Spread.Sheets.ConditionalFormatting.IconSetType.threeTriangles,
- iconIndex: 0,
- };
- icons[1] = {
- iconSetType: GC.Spread.Sheets.ConditionalFormatting.IconSetType.noIcons,
- iconIndex: 0,
- };
- icons[2] = {
- iconSetType:
- GC.Spread.Sheets.ConditionalFormatting.IconSetType.threeTriangles,
- iconIndex: 2,
- };
- var iconCriteria = iconSetRule.iconCriteria();
- iconCriteria[0] = new GC.Spread.Sheets.ConditionalFormatting.IconCriterion(
- false,
- GC.Spread.Sheets.ConditionalFormatting.IconValueType.number,
- 0
- );
- iconCriteria[1] = new GC.Spread.Sheets.ConditionalFormatting.IconCriterion(
- false,
- GC.Spread.Sheets.ConditionalFormatting.IconValueType.number,
- 10
- );
- iconSetRule.reverseIconOrder(false);
- iconSetRule.showIconOnly(false);
- sheet.conditionalFormats.addRule(iconSetRule);
复制代码 |