In my opinion, then best time to do these changes is when you CLOSE the workbook so the updates you've just completed cause the workbook to "move data" as the workbook is closing. When you open it next, those changes will have already be done.
Open the VB editor and paste this macro into the ThisWorkbook module:
Option Explicit
Private Sub Workbook_BeforeClose(Cancel As Boolean)
Dim LR As Long
Application.ScreenUpdating = False 'speed up macro
With Sheets("Action Log")
.AutoFilterMode = False 'remove prior filters
.Rows(1).AutoFilter 'add new filter
.Rows(1).AutoFilter 14, "Completed" 'filter col N for 'completed'
LR = .Range("A" & .Rows.Count).End(xlUp).Row 'find last row of visible data
If LR > 1 Then 'move data if any rows visible
.Range("A2:O" & LR).Copy Sheets("Completed").Range("A" & Rows.Count).End(xlUp).Offset(1)
.Range("A2:O" & LR).Delete xlShiftUp 'remove from Action Log
End If
.ShowAllData
.Rows(1).AutoFilter 10, "Yes" 'filter col J for 'yes'
LR = .Range("A" & .Rows.Count).End(xlUp).Row 'find last row of visible data
If LR > 1 Then 'move data if any rows visible
.Range("A2:O" & LR).Copy Sheets("Lessons Learned").Range("A" & Rows.Count).End(xlUp).Offset(1)
.Range("A2:O" & LR).Delete xlShiftUp 'remove from Action Log
End If
.AutoFilterMode = False 'remove autofilter
End With
ThisWorkbook.Save 'Save the changes
'The workbook should now close
Application.ScreenUpdating = True
End Sub
Bookmarks