Thank you for the response but Hold on... It doesn't work :(
I'm using Excel 2007 but saving it as Excel 97-03 Document due to compatibility issues within the company.
In case, I confused you, it's not working at all when a value is filtered out.
I've tried using
=MOD(SUBTOTAL(3,$A$2:$BK733),2)
=MOD(SUBTOTAL(103,$A$2:$BK733),2) 'To Ignore Hidden Cells
However, with no luck :'(
Moreover, when using this conditional formatting, the whole workbook was slowed down in terms of scrolling, keyboard translation movements, which is a critical issue.
I'll show you the whole VBA code of the filling odd rows (with hidden rows),
Code: Select all
Sub FillOnlyOddRows()
Application.ScreenUpdating = False
For c = 2 To Range("A" & Rows.count).End(xlUp).Row
If c Mod 2 = 1 Then
Rows(c).EntireRow.Interior.Color = RGB(220, 246, 255)
Else
Rows(c).EntireRow.Interior.Color = RGB(255, 255, 255)
End If
Next c
Application.ScreenUpdating = True
End Sub
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Row = 1 Then
Call FillOnlyOddRows
End If
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)
Call FillOnlyOddRows
End Sub
I would only run filling in odd rows when something is changed in the first row (that's where my autofilter is..)
It would work for sorting since there are no hidden rows.
but it wouldn't work for filtering out certain range of values (since there are hidden rows.)
Are there any ways to VB code it in manner of only filling color in visible rows alternatingly?
Thank you :)