Digita
03-15-2009, 11:08 PM
Hi guys,
Need your help on this. This code errors out on the command marked in red.
With ThisWorkbook.Sheets(1)
For Each cel In .Range("A6:A" & .Range("A6").End(xlDown).Row)
If unik = Empty Then
unik = cel
ElseIf InStr(1, unik, cel, 1) = 0 Then ' if unique
unik = unik & "," & cel
cel = Application.Substitute(cel, ",", "")
cel = Application.Substitute(cel, "Group", "")
Debug.Print cel & " - " & cel.Address
End If
Next
End With
Any idea why?
Thanks & regards
kp
Need your help on this. This code errors out on the command marked in red.
With ThisWorkbook.Sheets(1)
For Each cel In .Range("A6:A" & .Range("A6").End(xlDown).Row)
If unik = Empty Then
unik = cel
ElseIf InStr(1, unik, cel, 1) = 0 Then ' if unique
unik = unik & "," & cel
cel = Application.Substitute(cel, ",", "")
cel = Application.Substitute(cel, "Group", "")
Debug.Print cel & " - " & cel.Address
End If
Next
End With
Any idea why?
Thanks & regards
kp