Makro kürzen?
29.12.2004 17:39:24
Thomas
kann man dieses Makro kürzen?
Sub Zellen_Färben()
Dim c As Range
Application.ScreenUpdating = False
For Each c In Range("B3:K42")
If c. = "0 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "1 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "2 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "3 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "4 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "5 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = 6 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "7 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "8 0" Then
c.Interior.ColorIndex = 3
End If
Next c
For Each c In Range("B3:K42")
If c. = "9 0" Then
c.Interior.ColorIndex = 3
End If
Next c
Application.ScreenUpdating = True
End Sub
MfG Thomas.