SpreadJS Documentation
addDuplicateRule Method
The style that is applied to the cell when the condition is met.
The cell ranges where the rule is applied whose item type is GcSpread.Sheets.Range.
Adds a duplicate rule to the rule collection.
Syntax
var instance = new GcSpread.Sheets.ConditionalFormats(worksheet);
var value; // Type: object
value = instance.addDuplicateRule(style, ranges);
function addDuplicateRule( 
   style : Style,
   ranges : Array
) : object;

Parameters

style
The style that is applied to the cell when the condition is met.
ranges
The cell ranges where the rule is applied whose item type is GcSpread.Sheets.Range.

Return Value

The duplicate rule added to the rule collection.
Example
This example uses the addDuplicateRule method.
var style = new GcSpread.Sheets.Style(); 
style.backColor = "yellow"; 
activeSheet.setValue(0, 0, 50); 
activeSheet.setValue(1, 0, 50); 
activeSheet.setValue(2, 0, 11); 
activeSheet.setValue(3, 0, 5);
activeSheet.getConditionalFormats().addDuplicateRule(style, [new GcSpread.Sheets.Range(0,0,10,1)]);
See Also

Reference

ConditionalFormats type

 

 


Copyright © GrapeCity, inc. All rights reserved.

Send comments on this topic.