Find in Recorded Macro

R

Robert

I cannot seem to identify the mistake is this recorded (and edited) macro.
Thde query text will appear in cell B1. Would appreciate assistance. Thank
you.

Sub Macro1A()

Cells.Find(what:=.Range("B1").Value, After:=ActiveCell,
LookIn:=xlFormulas, LookAt _
:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext,
MatchCase:= _
False, SearchFormat:=False).Activate
End Sub
 
R

Rick Rothstein

You have a "dot" in front of the Range reference, but you don't have a With
statement for it to reference back to. Try removing that dot and see what
happens.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top