Thank you!
So this is my VB for when I check the box:
Dim rng As Range
Select Case Selection.Cells.Count
Case 1
Set rng = Cells
Case Else
Set rng = Selection
End Select
On Error Resume Next
rng.FormatConditions.Delete
On Error GoTo 0
Range("A4").Select
rng.FormatConditions.Add Type:=xlExpression, Formula1:="=$O4=1"
rng.FormatConditions(1).Interior.ColorIndex = 36
And then when I want to go back to the original formatting when its unchecked which is something like this:
Sub Blue()
Dim rng As Range
Select Case Selection.Cells.Count
Case 1
Set rng = Cells
Case Else
Set rng = Selection
End Select
Range("A4").Select
rng.FormatConditions.Add Type:=xlExpression, Formula1:="=$E4<=$E$2"
rng.FormatConditions(Selection.FormatConditions.Count).SetFirstPriority
With rng.FormatConditions(1).Interior
.PatternColorIndex = xlAutomatic
.ThemeColor = xlThemeColorLight2
.TintAndShade = 0.799981688894314
End With
rng.FormatConditions(1).StopIfTrue = False
rng.FormatConditions.Add Type:=xlExpression, Formula1:="=$O4=1"
rng.FormatConditions(Selection.FormatConditions.Count).SetFirstPriority
With rng.FormatConditions(1).Interior
.PatternColorIndex = xlAutomatic
.Color = 10092543
.TintAndShade = 0
End With
rng.FormatConditions(1).StopIfTrue = False
End Sub