Thread: Compile error
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Learning VBA Learning VBA is offline
external usenet poster
 
Posts: 23
Default Compile error

Thank you Dave
That appears to have done what I want it to.



"Dave Peterson" wrote in message
...
Maybe...

With Me.Range("B190")
If .Value 0 Then
ActiveSheet.Tab.ColorIndex = 6
Else
If .Value < 0 Then
ActiveSheet.Tab.ColorIndex = 3
Else
ActiveSheet.Tab.ColorIndex = 0
End If
end if
End With

Learning VBA wrote:

I am getting acompile error end with without with on this code.

With Me.Range("B190")
If .Value 0 Then
ActiveSheet.Tab.ColorIndex = 6
Else
If .Value < 0 Then
ActiveSheet.Tab.ColorIndex = 3
Else
ActiveSheet.Tab.ColorIndex = 0
End If
End With


--

Dave Peterson