I have 15 ranges in a worksheet that I need to track for changes, if the valuse changes to a value greater than zero, then I want to copy that row to "Sheet1". I can get the first range to work, but the subsequent ranges do not...
See Code Below...
Any assistance would be greatly appreciated...
Thank You
Jesse Lee
Private Sub Worksheet_Change(ByVal Target As Range)
Dim rng1 As Range
Dim LastRow As Object
' Set your Copy To range here
Set LastRow = Sheets("Sheet1").Range("A1342").End(xlUp)
' Only look at single cell changes
If Target.Count < 1 Then Exit Sub
' Set your change range here
Set rng1 = Range("C4:C9, C17:C21, C38:C32, I38:I48, F54:F64, C70:C1, C94:C97, C103:C106, C112:C116, C120:C122, C127:C130, D136:D145, I152:I161, I166:I172, F177F180")
' Only look at that range
If Intersect(Target, rng1) Is Nothing Then Exit Sub
' Set your condition here
If Target > 0 Then Target.EntireRow.Copy LastRow.Offset(1, 0)
End Sub
See Code Below...
Any assistance would be greatly appreciated...
Thank You
Jesse Lee
Private Sub Worksheet_Change(ByVal Target As Range)
Dim rng1 As Range
Dim LastRow As Object
' Set your Copy To range here
Set LastRow = Sheets("Sheet1").Range("A1342").End(xlUp)
' Only look at single cell changes
If Target.Count < 1 Then Exit Sub
' Set your change range here
Set rng1 = Range("C4:C9, C17:C21, C38:C32, I38:I48, F54:F64, C70:C1, C94:C97, C103:C106, C112:C116, C120:C122, C127:C130, D136:D145, I152:I161, I166:I172, F177F180")
' Only look at that range
If Intersect(Target, rng1) Is Nothing Then Exit Sub
' Set your condition here
If Target > 0 Then Target.EntireRow.Copy LastRow.Offset(1, 0)
End Sub