LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #9   Report Post  
Posted to microsoft.public.excel.misc
Max Max is offline
external usenet poster
 
Posts: 9,221
Default find certain text and display it

"natek1234" wrote
Actually I found my problem but dont really know how to correct it. I
was looking for "ENT" and it displays this when "statement" is in the
cell even though i used "FIND" and "ENT" by itself is before statement
in the cell.


Think you meant the upper case "STATEMENT"

Is there a way i can correct this so it searchs from left to right
and stops once it finds it or something else i need to do?


The search is already from left to right.

One way which may suffice here is to use a leading space for "ENT",
ie input it to search for string: <spaceENT
within the reference search list in E2:E6
instead of just: ENT

This will avoid it picking up STATEMENT
and you could just use TRIM on the return in col B

Also, when it doesnt find a match it displays "NA" is there a way
i can keep it blank if it doesnt find anything?


Yes, of course. Just add a front error trap: IF(ISNA(MATCH...),"",

With the error trap and TRIM bolted on,
try instead in B2, array-entered:
=IF(ISNA(MATCH(TRUE,ISNUMBER(FIND(E$2:E$6,A6)),0)) ,"",TRIM(INDEX(E$2:E$6,MATCH(TRUE,ISNUMBER(FIND(E$ 2:E$6,A6)),0))))
Copy B2 down as far as required
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Find max # and display name [email protected] Excel Discussion (Misc queries) 2 September 13th 07 09:17 PM
When I wrap text, excel hides the text display Vidyaji Excel Discussion (Misc queries) 4 March 12th 07 02:33 PM
HOW? Find and display the last cell in a column with a value 0 Conker10382 Excel Discussion (Misc queries) 10 July 22nd 06 02:02 AM
Find text within cell then display text to left Jambruins Excel Discussion (Misc queries) 5 April 17th 06 10:01 PM
trying to find how to display worksheet name in cell Yvonne Barber Excel Discussion (Misc queries) 1 September 15th 05 08:37 PM


All times are GMT +1. The time now is 01:32 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"