Hi everyone,
I'm wondering if someone can help me adjust the code is this other thread http://www.excelforum.com/excel-prog...in-cell-f.html so that it only transfers the values instead of any formulas in sheet 1.
Hi everyone,
I'm wondering if someone can help me adjust the code is this other thread http://www.excelforum.com/excel-prog...in-cell-f.html so that it only transfers the values instead of any formulas in sheet 1.
![]()
Private Sub Worksheet_Change(ByVal Target As Range) If Target.Column = 6 And Target.Cells.Count = 1 Then Target.EntireRow.Copy Sheets(2).Cells(Rows.Count, 1).End(xlUp).Offset(1).PasteSpecial xlValues Target.EntireRow.Delete shift:=xlUp End If End Sub
Thank you for your help. The code worked, but I am wondering if there is a way to change it a bit. I noticed that if I start typing into the wrong row of column six and delete it, the row still gets moved to sheet 2 when I leave the cell. I tried to change Target.Cells.Count=1 to Target.Value>0 (since I am entering a date into the cell). The macro works when I did that, but I get run-time error '13' at the end of it. Is there an easy way to fix this that I am missing?
Works great! Thank you so much!
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks