sharky12345
Well-known Member
- Joined
- Aug 5, 2010
- Messages
- 3,422
- Office Version
- 2016
- Platform
- Windows
I'm using this to try and identify which row a cell values appears on another sheet;
I am getting a Type Mismatch Error 13 on this line if anyone knows why;
For info, the cell B21 contains a lot of text and some numbers.
Code:
Dim YourVariable As VariantDim rowCount As Integer
Set YourVariable = Sheet21.Range("B2").Value
With ActiveSheet.Range("A:A")
Set uRng = .Find(YourVariable, , xlValues, xlWhole, , MatchCase:=False, searchformat:=False)
If Not uRng Is Nothing Then
uRng.Activate
rowCount = ActiveCell.Row
End If
End With
I am getting a Type Mismatch Error 13 on this line if anyone knows why;
Code:
Set YourVariable = Sheet21.Range("B2").Value
For info, the cell B21 contains a lot of text and some numbers.
Last edited: