Hi! Thank you for reading my quick question!
What I need: I select a cell, then a variable stores its value, and looks for it on worksheet "1" in column ("B:B").
Sub findstring()
Dim CurrValue As String
CurrValue = ActiveCell.Value
Sheets(1).Columns("B:B").Find(What:=CurrValue, After:=ActiveCell, LookIn:=xlFormulas,
LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False).Activate
End Sub
I highlighted the problem. (synctax error according to the debugger) Thank you for your answer!
What I need: I select a cell, then a variable stores its value, and looks for it on worksheet "1" in column ("B:B").
Sub findstring()
Dim CurrValue As String
CurrValue = ActiveCell.Value
Sheets(1).Columns("B:B").Find(What:=CurrValue, After:=ActiveCell, LookIn:=xlFormulas,
LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, _
MatchCase:=False, SearchFormat:=False).Activate
End Sub
I highlighted the problem. (synctax error according to the debugger) Thank you for your answer!
Last edited: