[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.IFormatCondition.NumberFormat

NumberFormat Property

NumberFormat

Gets or sets the number format applied to a cell if the conditional formatting rule evaluates to true.

This property returns the format string assigned to the conditional formatting rule.

Declaration
string NumberFormat { get; set; }
Property NumberFormat As String
Examples
worksheet.Range["A1:A3"].Value = new object[,] {{85}, {95}, {105}};
IFormatCondition condition = (IFormatCondition) worksheet.Range["A1:A3"]
    .FormatConditions.Add(FormatConditionType.CellValue, FormatConditionOperator.Greater, "90", null);
condition.Interior.Color = Color.Yellow;
condition.NumberFormat = "0.00";
string numberFormat = condition.NumberFormat;