Deleting or removing text from a line

herbc0704

Board Regular
Joined
Jun 22, 2009
Messages
100
I have a spreadsheet where I have to remove partial text for lines. I have seen this somehere before using the find and len functions but I can't fid the thread again.

Anyway, here is the problem.

I have inventory descriptions


Red Yarn m90
Red Yarn B753
Green Wooven Yarn X96884

In each case I need to remove right most m90, b753, x96884. I have over 60000 lines of different inventory items. What formula do I use or what thread can I find to accomplish this?
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
So you want to see up to (and including) the word Yarn?

Try

=LEFT(A1,FIND("Yarn",A1)+3)
 
Upvote 0
If it isn't always Yarn

=TRIM(SUBSTITUTE(A1,TRIM(RIGHT(SUBSTITUTE(A1," ",REPT(" ",255)),255)),""))
 
Upvote 0

Forum statistics

Threads
1,224,590
Messages
6,179,752
Members
452,940
Latest member
rootytrip

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