Defines the criterion for a [[ColorScaleConditionalFormat]] threshold.

See

  • [[ColorScaleConditionalFormat.minimumThreshold]]
  • [[ColorScaleConditionalFormat.maximumThreshold]]
  • [[ColorScaleConditionalFormat.midpointThreshold]]

Hierarchy

Hierarchy (view full)

Constructors

Properties

$type: Type
$t: Type
nextHashCode: number

Accessors

  • get formatColor(): WorkbookColorInfo
  • Returns or sets a [[WorkbookColorInfo]] object which defines the color information for the threshold associated with this instance.

    This property returns null if not explicitly set by the caller.

    Returns WorkbookColorInfo

  • set formatColor(a): void
  • Parameters

    Returns void

  • get formula(): Formula
  • Returns the formula which determines whether cell values meet the criteria defined by the associated condition.

    This property is only applicable when the [[valueType]] property is set to Formula.

    To assign a formula, use the [[setFormula]] method.

    See

    [[setFormula]]

    Returns Formula

  • get value(): number
  • Returns the numeric value for this instance.

    This property is read-only; to assign a value type, use the [[setValue]] or [[setValue]] methods.

    Note that the unit of measure for this value is determined by the [[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.

    See

    • [[valueType]]
    • [[formula]]
    • [[setValue]]

    Returns number

  • get valueType(): FormatConditionValueType
  • Returns a [[FormatConditionValueType]] value which specifies the manner in which the threshold values for this instance are determined.

    This property is read-only; to assign one of the following value types, use the [[setValue]] method:

    • AutomaticLowest
    • AutomaticHighest
    • LowestValue
    • HighestValue

    To assign a value type of Number, Percentage, or Percentileuse the [[setValue]] method.

    To assign a [[formula]], use the [[setFormula]] method.

    See

    [[setValue]]

    Returns FormatConditionValueType

Methods

  • Parameters

    • other: any

    Returns boolean

  • Returns number

  • Returns Base

  • Assigns the specified formula to the [[formula]] property, and assigns a value of Formula to the [[valueType]] property.

    See

    • [[formula]]
    • [[valueType]]
    • [[Formula]]

    Parameters

    • formula: string

      The string representation of the [[formula]] to be assigned to the [[value]] property.

    • Optional cellReferenceMode: CellReferenceMode

      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.

    • Optional valueType: FormatConditionValueType

      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'.

    Returns void

  • Sets the [[valueType]] property to the specified [[FormatConditionValueType]] value.

    The 'valueType' parameter must be set to one of the following values or an exception is thrown:

    • AutomaticLowest
    • AutomaticHighest
    • LowestValue
    • HighestValue

    To set the [[value]] property to a numeric value, use the [[setValue]] method.

    To set the [[valueType]] property to Formula, use the [[setFormula]] method.

    Parameters

    Returns void

  • Sets the [[value]] and [[valueType]] properties to the specified values.

    To set the [[valueType]] property to Formula, use the [[setFormula]] method.

    To set the [[valueType]] property to a [[FormatConditionValueType]] value for which the [[value]] is not applicable, use the [[setValue]] method.

    Parameters

    • value: number

      The new value for the [[value]] property.

    • valueType: FormatConditionValueType

      The new value for the [[valueType]] property. Must be set to either Number, Percentage, or Percentile or an exception is thrown.

    Returns void

  • Returns the string representation of this instance.

    Returns string

  • Parameters

    • item1: any
    • item2: any

    Returns number

  • Parameters

    • item1: any
    • item2: any

    Returns number

  • Parameters

    • item1: any
    • item2: any

    Returns boolean

  • Parameters

    • a: any
    • b: any

    Returns boolean

  • Parameters

    • obj: any

    Returns any[]

  • Parameters

    • obj: any

    Returns any[]

  • Parameters

    • obj: any

    Returns number

  • Parameters

    • a: any
    • b: any

    Returns boolean