ig.excel.ConditionValue
Remarks
When the ConditionValue.valueType property is set to Number, Percentage, or Percentile, only the ConditionValue.value property is applicable.
Similarly, the ConditionValue.formula property is only applicable whenValueType is set to Formula.
For the following settings of ValueType, neither Value nor Formula is applicable, and the actual threshold is derived based on the highest and/or lowest values in the associated range:
- AutomaticMinimum
- AutomaticMaximum
- LowestValue
- HighestValue
Dependencies
-
formula
- .formula( );
Returns the formula which determines whether cell values meet the criteria defined by the associated condition.
Remarks
This property is only applicable when the ConditionValue.valueType property is set to Formula.
To assign a formula, use the ConditionValue.setFormula method.
See Also
-
setFormula
- .setFormula( formula:string, [cellReferenceMode:ig.excel.CellReferenceMode], [valueType:ig.excel.FormatConditionValueType] );
Assigns the specified formula to the ConditionValue.formula property, and assigns a value of Formula to the ConditionValue.valueType property.
- formula
- Type:string
- The string representation of the ConditionValue.formula to be assigned to the ConditionValue.value property.
- cellReferenceMode
- Type:ig.excel.CellReferenceMode
- Optional
- A CellReferenceMode value which specifies whether the formula parameter should be interpreted as an A1 or R1C1 expression. This parameter is optional and defaults to null, in which case the Workbook.cellReferenceMode property is used.
- valueType
- Type:ig.excel.FormatConditionValueType
- Optional
- A FormatConditionValueType value which specifies the manner in which the value returned from the formula is interpreted. This parameter is optional and defaults to 'Formula'.
-
setValue
- .setValue( valueType:ig.excel.FormatConditionValueType );
Sets the ConditionValue.valueType property to the specified FormatConditionValueType value.
- valueType
- Type:ig.excel.FormatConditionValueType
- The new value for the ConditionValue.valueType property.
Remarks
The valueType parameter must be set to one of the following values or an exception is thrown:
- AutomaticLowest
- AutomaticHighest
- LowestValue
- HighestValue
To set the ConditionValue.value property to a numeric value, use the ConditionValue.setValue method.
To set the ConditionValue.valueType property to Formula, use the ConditionValue.setFormula method.
-
setValue
- .setValue( value:number, valueType:ig.excel.FormatConditionValueType );
Sets the ConditionValue.value and ConditionValue.valueType properties to the specified values.
- value
- Type:number
- The new value for the ConditionValue.value property.
- valueType
- Type:ig.excel.FormatConditionValueType
- The new value for the ConditionValue.valueType property. Must be set to either Number, Percentage, or Percentile or an exception is thrown.
Exceptions
Exception Description ig.ArgumentException If the value type or value is not appropriate for the condition. ig.ArgumentOutOfRangeException If the value is out of range. Remarks
To set the ConditionValue.valueType property to Formula, use the ConditionValue.setFormula method.
To set the ConditionValue.valueType property to a FormatConditionValueType value for which the ConditionValue.value is not applicable, use the ConditionValue.setValue method.
-
toString
- .toString( );
Returns the string representation of this instance.
-
value
- .value( );
Returns the numeric value for this instance.
Remarks
This property is read-only; to assign a value type, use the ConditionValue.setValue or ConditionValue.setValue methods.
Note that the unit of measure for this value is determined by the ConditionValue.valueType property; for example, when ValueType is set to Number, the value is interpreted as a numeric value, but when set to Percentage, it is interpreted as a percentage.
-
valueType
- .valueType( );
Returns a FormatConditionValueType value which specifies the manner in which the threshold values for this instance are determined.
Remarks
This property is read-only; to assign one of the following value types, use the ConditionValue.setValue method:
- AutomaticLowest
- AutomaticHighest
- LowestValue
- HighestValue
To assign a value type of Number, Percentage, or Percentileuse the ConditionValue.setValue method.
To assign a ConditionValue.formula, use the ConditionValue.setFormula method.
See Also