![]() |
#2
|
|||
|
|||
![]()
If any cell within your data area is blank, this will hide that row.
Code:
Sub HideRowsMissingData() Dim cl As Range, i As Integer Application.ScreenUpdating = False With Sheets("AutoFill") For Each cl In .Range("B6:B500") If cl.Value = "" Then .Rows(cl.Row).Hidden = True Else For i = 1 To 4 If cl.Offset(, i).Value = "" Then .Rows(cl.Row).Hidden = True Exit For End If Next i End If Next cl End With Application.ScreenUpdating = True End Sub Code:
Sub UnHideRows() Sheets("AutoFill").Rows.EntireRow.Hidden = False End Sub |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Split data in cells and duplicate rows | ballpoint | Excel Programming | 6 | 02-07-2018 05:52 PM |
eliminating blan rows between cells in a column cantaining data | FUGMAN | Excel Programming | 6 | 03-01-2017 07:35 AM |
Formula to hide '0' from blank referenced cells | formuladummy | Excel | 3 | 05-08-2014 02:33 AM |
Hide Rows | YounesB3 | Excel | 2 | 10-29-2012 05:40 AM |
![]() |
Spanec | Excel | 2 | 01-12-2012 09:15 AM |