after highlighting certain rows on a large spreadsheet, is it possible to make it view only the highlighted rows?
Sub paquirl()
Dim cl As Range
Dim lr As Long
lr = Cells(Rows.Count, 1).End(xlUp).Row
For Each cl In Range("A1:A" & lr)
If cl.Interior.ColorIndex = xlNone Then cl.EntireRow.Hidden = True
Next cl
End Sub
Sub paquirl2()
Dim lr As Long
lr = Cells(Rows.Count, 1).End(xlUp).Row
Range("A1:A" & lr).EntireRow.Hidden = False
End Sub
i have it as the following code. my screen flashes for a long time and then it finally seems to work! does my code need to be cleaned up, or is it supposed to flash like that?
Sub paquirl()
'
' paquirl Macro
' Macro recorded 3/11/2011 by Andrew Quirl
'
' Keyboard Shortcut: Ctrl+Shift+Q
Dim cl As Range
Dim lr As Long
lr = Cells(Rows.Count, 1).End(xlUp).Row
For Each cl In Range("A1:A" & lr)
If cl.Interior.ColorIndex = xlNone Then cl.EntireRow.Hidden = True
Next cl
End Sub
Sub paquirl()
'
' paquirl Macro
' Macro recorded 3/11/2011 by Andrew Quirl
'
' Keyboard Shortcut: Ctrl+Shift+Q
Dim cl As Range
Dim lr As Long
Application.Screenupdating = false
lr = Cells(Rows.Count, 1).End(xlUp).Row
For Each cl In Range("A1:A" & lr)
If cl.Interior.ColorIndex = xlNone Then cl.EntireRow.Hidden = True
Next cl
Application.Screenupdating = true
End Sub
now it's not working at all.