Dim melt As Long ''Row where the data will insert melt = 5 For x = 1 To lastRow ''Search if If (Sheets("SchedData").Cells(x, 9) = "melt") And Sheets("SchedData").Cells(x, 1) = Sheet23.Range("Q2") Then ''Get and insert data Sheet23.Cells(melt, 2) = Sheets("SchedData").Cells(x, 6) Sheet23.Cells(melt, 3) = Sheets("SchedData").Cells(x, 5) melt = melt + 1 count = count + 1 End If Next x ''Hide all the cell within the range that is empty For Each c In Range("B5:B20") If c.Value = "" Then c.EntireRow.Hidden = True Else c.EntireRow.Hidden = False End If Next
EntireColumn.Hidden
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)