Creates a Condition of the specified ComparisonType.

 public Condition CreateCondition(Comparison comparisonType, System.String formula1, System.String formula2)
Public Function CreateCondition(ByVal comparisonType As Comparison, ByVal formula1 As String, ByVal formula2 As String) As Condition

A Condition constant representing the type of comparison Excel will use when comparing a cell value to the parameters formula1 and formula2. The comparison type must require two formulas and may be set to one of the following values: Condition.Comparison.CellValueBetween or Condition.Comparison.CellValueNotBetween..

The formula to use for the minumum value.

The formula to use for the maximum value.

A Condition object representing the condition created.

          ExcelApplication xla = new ExcelApplication();
          Workbook wb = xla.Create();
          Range rng = wb.Worksheest[0].CreateRange("$B$2:$F$10");
          ConditionalFormat condFmt = wb.CreateConditionalFormat();
          Condition cond =
          Font fnt = cond.Style.Font;
          fnt.Bold = true;
          fnt.Color = wb.Palette.GetClosestColor(100, 100, 255);

          Dim xla As New ExcelApplication()
          Dim wb As Workbook = xla.Create()
          Dim rng As Range = wb.Worksheets(0).CreateRange("$B$2:$F$10")
          Dim condFmt As ConditionalFormat = wb.CreateConditionalFormat()
          Dim cond As Condition = _
               condFmt.CreateCondition( _
               Condition.Comparison.CellValueBetween, _
               "=100", _
          Dim fnt As Font = cond.Style.Font
          fnt.Bold = True
          fnt.Color = wb.Palette.GetClosestColor(100, 100, 255)