flyfishing2542
New Member
- Joined
- Jan 27, 2009
- Messages
- 11
I have searched through years of conditional formating posts and VB posts(which I am TOTALLY lost in)
My issue doesnt seem difficult to me... but after days of screaming at my monitor.... /sigh please hel
On my Sheet 1, I have a column that has caculated numbers in it and when that number dips below 50 I want it to blink/flash red.
I have tried this code.
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Value = 55 Then
For n = 1 To 10
Target.Interior.Color = vbRed
Delay (0.04)
Target.Interior.ColorIndex = xlNone
Delay (0.04)
Next n
End If
End Sub
Sub Delay(rTime As Single)
'delay rTime seconds (min=.01, max=300)
Dim oldTime As Variant
'safety net
If rTime < 0.01 Or rTime > 300 Then rTime = 1
oldTime = Timer
Do
DoEvents
Loop Until Timer - oldTime > rTime
End Sub
and EVERY other one I found here and other locations... I have tried just to make them work... which either my excel is too old or I am.
so someone please help...
thank you for your help.
My issue doesnt seem difficult to me... but after days of screaming at my monitor.... /sigh please hel
On my Sheet 1, I have a column that has caculated numbers in it and when that number dips below 50 I want it to blink/flash red.
I have tried this code.
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Value = 55 Then
For n = 1 To 10
Target.Interior.Color = vbRed
Delay (0.04)
Target.Interior.ColorIndex = xlNone
Delay (0.04)
Next n
End If
End Sub
Sub Delay(rTime As Single)
'delay rTime seconds (min=.01, max=300)
Dim oldTime As Variant
'safety net
If rTime < 0.01 Or rTime > 300 Then rTime = 1
oldTime = Timer
Do
DoEvents
Loop Until Timer - oldTime > rTime
End Sub
and EVERY other one I found here and other locations... I have tried just to make them work... which either my excel is too old or I am.
so someone please help...
thank you for your help.