Hi,
Below is the code in which the macro is showing error
Run time error '1004'
Application-defined (or) Object defined error
at
Cells(currow, "C") = finalNum2
Sub test()
Dim finalNum2 As String
dim D r as range
Dim C As Range
Dim myArray, myArray2
Dim x As Integer
myArray = Array("Project1", "Project2")
myArray2 = Array("H", "P")
For Each r In ActiveSheet.Range("F2:F100")
For x = LBound(myArray) To UBound(myArray)
Set C = r.Find(myArray(x), LookIn:=xlValues, MatchCase:=False)
If Not C Is Nothing Then
finalNum2 = finalNum & "-" & myArray2(x)
Cells(currow, "C") = finalNum2
exit for
End If
Next x
Next r
End Sub
Bookmarks