Strooprover
New Member
- Joined
- Jul 21, 2017
- Messages
- 25
Hi,
When I try this the red line gives the error: object variable or With block not set.
Can someone explain where I go wrong?
Thanks in advance!
When I try this the red line gives the error: object variable or With block not set.
Can someone explain where I go wrong?
Thanks in advance!
Code:
Dim tabel As String
tabel = Range("A1").Value
For x = 1 To 1000
[COLOR=#ff0000]If ws2.Cells(x, 1) = tabel Then[/COLOR]
ws2.Cells(x, 1).Select
End If
Next x