I am looking for a way to modify this current VBA code I have working. What it is currently doing is once anything in column 7 is "yes" it will copy the entire row to the next available row of another sheet titled "Error Log".
However what I want it to do is only copy "cell A, E and F" from the same row that the "yes" has been met. My current code is below. Help is greatly appreciated!
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 7 Then
If Target = "Yes" Then
Application.EnableEvents = False
nxtRow = Sheets("Error Log").Range("A" & Rows.Count).End(xlUp).Row + 1
Target.EntireRow.Copy _
Destination:=Sheets("Error Log").Range("A" & nxtRow)
End If
End If
Application.EnableEvents = True
End Sub
However what I want it to do is only copy "cell A, E and F" from the same row that the "yes" has been met. My current code is below. Help is greatly appreciated!
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 7 Then
If Target = "Yes" Then
Application.EnableEvents = False
nxtRow = Sheets("Error Log").Range("A" & Rows.Count).End(xlUp).Row + 1
Target.EntireRow.Copy _
Destination:=Sheets("Error Log").Range("A" & nxtRow)
End If
End If
Application.EnableEvents = True
End Sub