Good day, I'm looking to make the following code more efficient. Any suggestions would be greatly appreciated! Thank you in advance.
Sub DataVerifier()
'"""""""""Application Settings""""""""
Application.DisplayAlerts = False 'Stops the program from asking if it is ok for the macro to delete sheets
Application.ScreenUpdating = False 'Stops program from showing what is happening when the macro is running
Application.EnableEvents = False
Application.Calculation = xlCalculationManual
'"""""""""""""""""""""""""""""""""""""
Dim lastRow As Long 'What row the last data point is in the new sheet (used for formula configuration)
Dim sht As Worksheet
Sheets(1).Select 'Adds a sheet to front of book and names it combined, this will contain all data in one sheet
Dim j As Integer 'Loops through the sheets, selecting all cells on the sheet and moving them to sheet "Combined"
For j = 2 To Sheets.Count
Sheets(j).Activate
Range("A1").Select
Selection.CurrentRegion.Select
Selection.Copy Destination:=Sheets(1).Range("A1000000").End(xlUp)
Next j
Sheets(1).Activate
Dim i As Long
For i = 2 To 50000
If (Cells(i, 5) < 1 And Cells(i, 5) > -1 And Cells(i, 5) <> "") Then
Cells(i, 6) = 1
End If
Next i
Dim k As Long
For k = 2 To 50000
If (Cells(k, 6) = 1) Then
Range(Cells(k, 1), Cells(k, 6)).Delete Shift:=xlUp
End If
Next k
'"""""""""Application Settings""""""""
Application.DisplayAlerts = True 'Stops the program from asking if it is ok for the macro to delete sheets
Application.ScreenUpdating = True 'Stops program from showing what is happening when the macro is running
Application.EnableEvents = True
Application.Calculation = xlCalculationAutomatic
'"""""""""""""""""""""""""""""""""""""
End Sub