From: simonc on 28 Apr 2010 12:08 I couldn't understand why the find method wasn't working in a macro until I realised that the range of cells I was searching didn't contain actual text, but the result of formulae referring to text in another worksheet. Is there a way of using find so that it will identify if the result of a formula matches the text you're searching for? Grateful for advice.
From: joel on 28 Apr 2010 12:32 Set SearchRange = Sheets("sheet1").Range("A1:A100") set c = SearchRange(what:="ABC", lookin:=xlvalues,lookat:=xlwhole) if c is nothing then msgbox("Nothing found") else msgbox("Found at : " & c.address(external:=true)) end if -- joel ------------------------------------------------------------------------ joel's Profile: http://www.thecodecage.com/forumz/member.php?u=229 View this thread: http://www.thecodecage.com/forumz/showthread.php?t=199159 http://www.thecodecage.com/forumz
|
Pages: 1 Prev: VBA to open a PDF, print, then close - Stumped Next: SUMPRODUCT is not working |