Gruppe
Ereignis
Problem
Beim Filtern einer Spalte soll die Kopfzeile gelb hinterlegt werden.
ClassModule: Tabelle1
Private Sub Worksheet_Calculate()
Dim flt As Filter
Dim iCol As Integer
For Each flt In ActiveSheet.AutoFilter.Filters
iCol = iCol + 1
If flt.On Then
Cells(1, iCol).Interior.ColorIndex = 6
Else
Cells(1, iCol).Interior.ColorIndex = _
xlColorIndexNone
End If
Next flt
End Sub