Had a 4shared account myself. Here's what you can try for the first macro
Code:Sub Find_missed_devices() Dim shtInitiatingDevices As Worksheet, shtMissedInspectionItems As Worksheet Dim lngLastRow As Long Dim rngEach As Range, rng As Range Set shtInitiatingDevices = Sheets("INITIATING DEVICES") Set shtMissedInspectionItems = Sheets("MISSED INSPECTION ITEMS") 'Set the range for the inspection results column lngLastRow = shtInitiatingDevices.Cells(Rows.Count, 2).End(xlUp).Row Set rng = shtInitiatingDevices.Range("E7:E" & lngLastRow) 'Isolate the missing or empty results columns and copy rows to sheet 2 (MISSED INSPECTION ITEMS) Application.EnableEvents = False For Each rngEach In rng If Len(Trim(rng.Value)) = 0 Or UCase(rng.Value) = "NO ACCESS" Then rng.Offset(, -4).Resize(, 5).Copy shtMissedInspectionItems.Cells(shtMissedInspectionItems.Rows.Count, 1).End(xlUp)(2) End If Next rngEach With shtMissedInspectionItems If Application.CountIf(.Range("C7", .Cells(Rows.Count, 3).End(xlUp).Offset(0, 1)), "") > 0 Then .Range("C7", .Cells(Rows.Count, 3).End(xlUp).Offset(0, 1)).SpecialCells(xlCellTypeBlanks).EntireRow.Delete End If End With Application.EnableEvents = True End Sub




Reply With Quote
Bookmarks