I have created a simple inventory of my DVD's and Cd's. Three sheets in my workbook, At Home, Loaned Out and On Hold. Column C, in each sheet, which is named Status has a dropdown list with three choices, happen to also be At Home, Loaned out and On Hold. What I am after is when I choose the dropdown list I would like that row to be moved to the corresponding sheet. My current VBA will move the row from At Home sheet to Loaned out, can't figure out how to get them to move back and forth. This is the code that is attached to the At Home sheet, when I put this on the Loaned Out sheet and change it accordingly it doesn't work. Any Suggestions?
Option Explicit
Private Sub Worksheet_change(ByVal target As Range)
If target.Count > 1 Then Exit Sub
If target.Column <> 3 Then Exit Sub
If target.Value <> "Loaned Out" Then Exit Sub
Dim i&
With Sheets("Loaned Out")
i = .Cells(Rows.Count, 1).End(xlUp).Row: If i = 1 Then i = 2
target.EntireRow.Copy Destination:=.Cells(i + 1, 1)
End With
target.EntireRow.Delete
End Sub
Bookmarks