Thread: finding text
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default finding text

I guess you wanted a worksheet formula

=if(countif(cell,"*123*"),"found","not found")

is another to add to the collection.

--
Regards,
Tom Ogilvy

"Tom Ogilvy" wrote in message
...
if instr(1,cell,"123",vbTextCompare) 0 then
msgbox "contains 123"
End if

if cell like "*123*" then
msgbox "contains 123"
End if

--
Regards,
Tom Ogilvy

"Fish" wrote in message
...
Is it possible to code a find to determine if any part of
a value is in a text for instance:

=RIGHT(cell,3) xxx123 gives 123

is it possible to just code to find 123 in a text