Hello All,
Thanks for your help in advance. I created this macro below which hides/unhides the entire row if value is zero. Everything works fine until the spreadsheet is asked to hide too many rows and then crashes. Is there a work-around here? I am at a loss...
Sub Hide_Rows_Containing_Value_All_Sheets()
Dim c As Range
Dim ws As Worksheet
For Each ws In ActiveWorkbook.Worksheets
For Each c In ws.Range("DD8:DD12,DD19:DD28,DD35:DD209").Cells
If c.Value = "Yes" Then
c.EntireRow.Hidden = True
End If
Next c
Next ws
End Sub
Sub Unhide_All_Rows()
For Each ws In ActiveWorkbook.Worksheets
For Each c In ws.Range("DD8:DD12,DD19:DD28,DD35:DD209").Cells
If c.Value = "Yes" Then
c.EntireRow.Hidden = False
End If
Next c
Next ws
End Sub
Thanks for your help in advance. I created this macro below which hides/unhides the entire row if value is zero. Everything works fine until the spreadsheet is asked to hide too many rows and then crashes. Is there a work-around here? I am at a loss...
Sub Hide_Rows_Containing_Value_All_Sheets()
Dim c As Range
Dim ws As Worksheet
For Each ws In ActiveWorkbook.Worksheets
For Each c In ws.Range("DD8:DD12,DD19:DD28,DD35:DD209").Cells
If c.Value = "Yes" Then
c.EntireRow.Hidden = True
End If
Next c
Next ws
End Sub
Sub Unhide_All_Rows()
For Each ws In ActiveWorkbook.Worksheets
For Each c In ws.Range("DD8:DD12,DD19:DD28,DD35:DD209").Cells
If c.Value = "Yes" Then
c.EntireRow.Hidden = False
End If
Next c
Next ws
End Sub