conditional formatting

  • Thread starter Thread starter Guest
  • Start date Start date
What do you mean by code? How do I do that? I want a worksheet to evaluate
a cell. If the cell is less than 120, then I want the tab to turn red.

Thanks,
rob
 
Rob

Something like this in the worksheet_change() event

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Target, Range("A1")) Is Nothing Then
If Target.Value = 120 Then
Me.Tab.Color = RGB(255, 0, 0)
Else
Me.Tab.Color = xlNone
End If
End If
End Sub

--
HTH
Nick Hodge
Microsoft MVP - Excel
Southampton, England
www.nickhodge.co.uk
(e-mail address removed)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top