Sensitive String

How to pull a word out of a string of text in a cell and place it in a new cell in Excel?

Let's say a cell has the text string "I like to use computers." How would I go about writing a formula in Excel or Visual Basic for Excel that would enable me to find if the cell has the word "use" in it, and if it does, copy that word into a new cell?

Or is there a way that I can use boolean operators such as "If the cell contains the word 'use', then print the word 'True' in this new cell."

Thanks

if you are not looking for anything complicated (like your sentance in cell A1), then this formula will work in cell B1

=IF(ISERROR(FIND("use",A1)), FALSE,TRUE)

- find() will find the case sensitive string "use"
- if it doesnt find "use" then it will give a #value error
- this is why i used the iserror() formula...it checks for errors and give a true/false
- and you need to If() statement to reverse the true/false values.
- search() is similar, but is not case sensitive.
- find() looks for strings...so useless and useful produce true

edit-
i guess you could put 2 spaces inside the quotes like " use ", and that would find the word use. but if "use" starts or ends a sentence...you will have a problem.

bottom line=
go with the vba

Discover Sensitive String On eBay Below:



Recently Purchased Sensitive String:


super sensitive red label viola strings set standard 151612 free shipping, viola d strings supersensitive red label musical strings co usa, viola c strings supersensitive musical strings co usa, super sensitive 4137 supersensitive viola g string, super sensitive red label 14 viola string set , super sensitive red label junior 13 viola string set



Comments are closed.