- Katılım
- 15 Mart 2005
- Mesajlar
- 43,668
- Excel Vers. ve Dili
- Microsoft 365 Tr-En 64 Bit
DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Sub Renkleri_Sil()
Range("I:L").Interior.ColorIndex = xlNone
End Sub
Sub Renklendir()
Dim S1 As Worksheet, Veri As Range, Son_Veri As Long, Son_Kod As Long
Application.ScreenUpdating = False
Set S1 = Sheets("Renkler")
Son_Kod = S1.Cells(S1.Rows.Count, "A").End(3).Row
Son_Veri = Cells(Rows.Count, "I").End(3).Row
Range("I:L").FormatConditions.Delete
For Each Veri In S1.Range("A2:A" & Son_Kod)
With Range("I2:L" & Son_Veri)
.FormatConditions.Add Type:=xlExpression, Formula1:="=AND($I2<>"""";$I2=""" & Veri.Value & """)"
.FormatConditions(.FormatConditions.Count).SetFirstPriority
With .FormatConditions(1).Interior
.PatternColorIndex = xlAutomatic
.ColorIndex = Veri.Offset(0, 1)
.TintAndShade = 0
End With
.FormatConditions(1).StopIfTrue = False
End With
With Range("I2:L" & Son_Veri)
.FormatConditions.Add Type:=xlExpression, Formula1:="=AND($J2<>"""";$J2=""" & Veri.Offset(, 2).Value & """)"
.FormatConditions(.FormatConditions.Count).SetFirstPriority
With .FormatConditions(1).Interior
.PatternColorIndex = xlAutomatic
.ColorIndex = Veri.Offset(0, 3)
.TintAndShade = 0
End With
.FormatConditions(1).StopIfTrue = False
End With
Next
Application.ScreenUpdating = True
End Sub