Extracting words from a cell

manzier

Board Regular
Joined
Jul 21, 2014
Messages
96
Hi all, I'm having trouble with a formula to extract words from a cell. I found out how to do it in cases where the word I want to extract is always in the same place, but have no idea how to do it when the order is variable. See example below



[TABLE="width: 500"]
<tbody>[TR]
[TD]Text[/TD]
[TD]Example 3 Word[/TD]
[/TR]
[TR]
[TD]Example 1: Bacon, Example 2: Sausage, Example 3: Eggs, Example 4: Chips[/TD]
[TD]Eggs[/TD]
[/TR]
[TR]
[TD]Example 3: Tomatoes, Example 5: Bread[/TD]
[TD]Tomatoes[/TD]
[/TR]
[TR]
[TD]Example 2: Tacos, Example 3: Cheese, Example 6: Rice
[/TD]
[TD]Cheese[/TD]
[/TR]
</tbody>[/TABLE]

In the example above I need to extract the word between "Example 3: " and "," but as you can see it can be in any position in the cell.

Any advice? Thanks in advance!
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
If you are always looking for the item after "Example 3" then try:

=TRIM(MID(A2,FIND("Example 3:",A2)+10,FIND(",",A2,FIND("Example 3:",A2))-FIND("Example 3:",A2)-10))
 
Upvote 0

Forum statistics

Threads
1,224,829
Messages
6,181,222
Members
453,024
Latest member
Wingit77

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top