Greg has attended:
Excel Advanced course
Excel VBA Intro Intermediate course
Making cells flash in Excel
Please could you advise how to make a cell in excel flash if a value in an adjacent cell meets certain criteria? Eg if the value is > 500 then the cell should flash.
Many thanks,
Greg
RE: Making cells flash in Excel
Does this help?
'==================================================================================
'- This code goes into Worksheet module (right click tab. View Code)
'==================================================================================
Dim Flash As Boolean
'==================================================================================
'- CELL DOUBLE CLICK to start & stop 'flash'
'==================================================================================
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
If Target.Address = "$A$1" Then
Flash = Not Flash
FLASHCELL
End If
End Sub
'==================================================================================
'- CELL CHANGES COLOUR UNTIL Flash=False
'==================================================================================
Private Sub FLASHCELL()
While Flash = True
F = Range("A1").Interior.ColorIndex
F = IIf(F = 3, 0, 3)
Range("A1").Interior.ColorIndex = F
Application.Wait Now + TimeValue("00:00:01")
DoEvents
Wend
Range("A1").Interior.ColorIndex = 3
End Sub