Ich habe es mal hinzugefügt eine weitere findvalue code, jedoch kriege ich ständig die fehlermeldung
"typ unverträglich"
Dim
cell
As
Range
r = 2
number_of_r = 30
ru = 1
number_of_ru = 30
For
Each
cell
In
ws.Range(
"A"
& r &
":A"
& number_of_r)
For
I = 0
To
2
Set
foundValue = wp.Sheets(
"ABC"
).Range(Cells(ru, I +
1), Cells(number_of_ru, I + 1)).Find(cell.Offset(0, I).Value)
If
Not
foundValue
Is
Nothing
Then
wp.Sheets(
"ABC"
).Rows(foundValue.Row).Columns(
"E:AB"
).Copy
ws.Range(
"G"
& cell.Row).PasteSpecial
GoTo
nextCell
End
If
Next
I
Set
foundValue = wp.Sheets(
"ABC"
).Range(Cells(ru, I + 1), Cells(number_of_ru, I + 1)).Find(cell.Offset(0, I).Value)
And
wp.Sheets(
"ABC"
).Range(Cells(ru, I + 2), Cells(number_of_ru, I + 2)).Find(cell.Offset(0, I + 1).Value)
If
Not
foundValue
Is
Nothing
Then
wp.Sheets(
"ABC"
).Rows(foundValue.Row).Columns(
"E:AB"
).Copy
ws.Range(
"G"
& cell.Row).PasteSpecial
GoTo
nextCell
Else
: MsgBox
"Problem"
End
If
nextCell:
Next
cell
End
sub