What cell am I on ?

  • Thread starter Thread starter Rich
  • Start date Start date
R

Rich

I wanted to do the following. I issue the find command to find a
certain text. Once found, I want to apply the cell address to a memory
variable. So the code might look this :

Cells.Find(What:="Totals", After:=ActiveCell, LookIn:=xlFormulas,
LookAt _
:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext,
MatchCase:= _
False).Activate

lcAddress = ????

How do I do the above.
 
Rich,

Try this:

Sub TestMe()
Dim icAddr As String
icAddr = Cells.Find(What:="Totals", _
After:=ActiveCell, _
LookIn:=xlFormulas, _
LookAt:=xlPart, _
SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False).Address
MsgBox icAddr
End Sub

John
 
Back
Top