View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.misc
JE McGimpsey JE McGimpsey is offline
external usenet poster
 
Posts: 4,624
Default Partial string search w/o VBA?

One way, perhaps:

=FIND("1YearSelfMaintenance", SUBSTITUTE(SUBSTITUTE(A1, " ", ""),
"-", ""))



In article ,
MJW wrote:

Hi All,

As useful as the MID, LEFT and RIGHT functions are for FIND, I'm having an
issue which I hope isn't much of one at all. I'm looking to validate a
certain text value inside a adjacent cell, but the problem is that it can
fall in multiple locations in the cell because of how the the processor
enters the data (IE: "1-Year Self-Maintenance", "1 Year Self-Maintenance",
"1-Year Self Maintenance", etc...); the differences are subtle, but enough to
throw off a static search. Is there an easy way to perform this without
coding it in VBA? Heck, is there ANY way to do this without VBA? :) I'm
looking at approximately 60 possible combinations of that kind of string (not
only is there a formatting concern, but the numerical value can equal 1-5 as
well), and Excel would laugh at me if I even TRIED a formula with that many
nested IF's and OR's. Any help would be greatly appreciated.

Thanks

Jamie W.