Barryj
08-08-2011, 08:09 AM
I am trying to get this macro to copy over column 3 to 2, but it shows subscript out of range, am I missing somthing simple?
Sub test()
Dim r As Range, e
For Each e In Array(Array("SPOT", "SPOT"), Array("TICK", "TICK"), Array("LEAVE", "LEAVE"))
Set r = Columns(3).Find(e(0), , , xlPart, , , False)
If Not r Is Nothing Then
r(3, 2).Value = e(3)
End If
Next
End Sub
Thanks
Sub test()
Dim r As Range, e
For Each e In Array(Array("SPOT", "SPOT"), Array("TICK", "TICK"), Array("LEAVE", "LEAVE"))
Set r = Columns(3).Find(e(0), , , xlPart, , , False)
If Not r Is Nothing Then
r(3, 2).Value = e(3)
End If
Next
End Sub
Thanks