Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Columns("H:H")) Is Nothing Then Exit Sub
If Target.Value = "General" Then
Range(Range("C" & Target.Row), Range("H" & Target.Row)).Copy _
Sheets("General").Range("C" & Rows.Count).End(xlUp).Offset(1, 0)
ElseIf Target.Value = "1ste Group" Then
Range(Range("C" & Target.Row), Range("H" & Target.Row)).Copy _
Sheets("1ste Group").Range("C" & Rows.Count).End(xlUp).Offset(1, 0)
End If
End Sub
If Intersect(Target, Columns("G:G")) Is Nothing Then Exit Sub
Range(Range("A" & Target.Row), Range("G" & Target.Row)).Copy
Sheets("WellsFargo").Range("C" & Rows.Count).End(xlUp).Offset(1, 0)
Private Sub Worksheet_Change(ByVal Target As Range) If Intersect(Target, Columns("A:A")) Is Nothing Then Exit Sub Target.EntireRow.Copy Sheets(Target.Value).Range("A" & Rows.Count).End(xlUp).Offset(1, 0) End Sub
Private Sub Worksheet_Change(ByVal Target As Range) If Intersect(Target, Columns("B:B")) Is Nothing Then Exit Sub target.entirerow.Copy Sheets(Target.Value).Range("A" & Rows.Count).End(xlUp).Offset(1, 0) End Sub
Private Sub Worksheet_Change(ByVal Target As Range) If Intersect(Target, Columns("D")) Is Nothing Then Exit Sub Dim mFind As Range Target.EntireRow.Copy If Target.Value Like "*AS*" Then Set mFind = Sheets("AS").Columns("A").Find(Target.Offset(0, -3)) If mFind Is Nothing Then Sheets("AS").Range("A" & Rows.Count).End(xlUp).Offset(1, 0).PasteSpecial Else mFind.PasteSpecial End If End If If Target.Value Like "*BB*" Then Set mFind = Sheets("BB").Columns("A").Find(Target.Offset(0, -3)) If mFind Is Nothing Then Sheets("BB").Range("A" & Rows.Count).End(xlUp).Offset(1, 0).PasteSpecial Else mFind.PasteSpecial End If End If If Target.Value Like "*JS*" Then Set mFind = Sheets("JS").Columns("A").Find(Target.Offset(0, -3)) If mFind Is Nothing Then Sheets("JS").Range("A" & Rows.Count).End(xlUp).Offset(1, 0).PasteSpecial Else mFind.PasteSpecial End If End If Application.CutCopyMode = False End Sub
Private Sub Worksheet_Change(ByVal Target As Range) If Intersect(Target, Columns("G:G")) Is Nothing Then Exit Sub target.entirerow.Copy _ Sheets(target.value).Range("A" & Rows.Count).End(xlUp).Offset(1, 0)
Private Sub Worksheet_Change(ByVal Target As Range) Dim mSheet As String If Intersect(Target, Columns("E")) Is Nothing Then Exit Sub mSheet = Target.Value Target.EntireRow.Copy _ Sheets(mSheet).Range("A" & Rows.Count).End(xlUp).Offset(1, 0) End Sub
Thanks for your code.
I used the code segment successfully,. But, on reopening the file after saving with macro enabled, the code does not seem to run!
What should I do?
Davis
That is strange, saving your file shouldn't alter the way the code works in any way.
I wouldn't mind taking a look at your file to see what is going on.
Use a free file sharing site like www.speedyshare.com or ge.tt to upload your file and then post back the download link. Always be careful with sensitive information.
I'll get back to you next week, though.
Best regards,
Trowa
Problem solved.
I had to "Enable Content" Then it is working beautifully.
Sorry for the trouble.
Thanks
Davis