Sets conditional formatting for a specified cell on the sheet based on a specified formula.
Syntax
Visual Basic (Usage) | Copy Code |
---|
Dim instance As SheetView
Dim row As Integer
Dim column As Integer
Dim style As NamedStyle
Dim formula As String
Dim value As Boolean
value = instance.SetFormulaConditionalFormat(row, column, style, formula) |
Parameters
- row
- Row index of the cell
- column
- Column index of the cell
- style
- Style to be applied to the cell if the formula evaluates to true
- formula
- Formula to evaluate for the condition
Example
This sets a conditional format for the specified cell.
C# | Copy Code |
---|
FarPoint.Win.Spread.NamedStyle style = new FarPoint.Win.Spread.NamedStyle();
style.BackColor = Color.Cyan;
fpSpread1.ActiveSheet.SetFormulaConditionalFormat(0, 0, style, "A1 = 10");
fpSpread1.ActiveSheet.Cells[0, 0].Value = 10; |
Visual Basic | Copy Code |
---|
Dim style As New FarPoint.Win.Spread.NamedStyle
style.BackColor = Color.Cyan
FpSpread1.ActiveSheet.SetFormulaConditionalFormat(0, 0, style, "A1 = 10")
FpSpread1.ActiveSheet.Cells(0, 0).Value = 10 |
Requirements
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
See Also