Вы находитесь на странице: 1из 1

Sub StartBlink()

Dim xCell As Range

Dim xTime As Variant

Set xCell = Range("E2")

With ThisWorkbook.Worksheets("Sheet1").Range("E2").Font

If xCell.Font.Color = vbRed Then

xCell.Font.Color = vbBlue

ElseIf xCell.Font.Color = vbBlue Then

xCell.Font.Color = vbYellow

ElseIf xCell.Font.Color = vbYellow Then

xCell.Font.Color = vbPink

Else

xCell.Font.Color = vbRed

End If

End With

xTime = Now + TimeSerial(0, 0, 1)

Application.OnTime xTime, "'" & ThisWorkbook.Name & "'!StartBlink", , True

End Sub

Вам также может понравиться