If values in two columns are equal I want to automatically execute a macro

T

Tom Rinks

If values in two columns are equal, I want to automatically execute
macro that will move the entire record to another sheet and delete th
row that the record was in
 
T

Tom Ogilvy

If cells(rw,col1).value = cells(rw,col2).value then
cells(rw,col1).Entirerow.copy Destination:= _
ws.cells(rw.count,1).end(xlup)(2)
cells(rw.col1),Entirerow.delete
End if
 
Top