Truncate vaiable text strings???

esponapule

New Member
Joined
Sep 30, 2009
Messages
5
Is there a formula to remove everything after a certain character for variable text strings?

for example:

Turnthis...
Code:
Single basin|,Double basin|,Triple basin|
Double handle|,Single handle|,Touchless|
Single hole|,Two holes|,Three holes|,Four holes|,Single hole with deck plate|
into this:
Code:
Single basin
Double handle
Single hole


Thanks!
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
THAT WORKED!!!

I had to change it a little, a1 is the result so I used col. B

THANKS!! I also learned a new command too!

awesome :)
 
Upvote 0
Now, if you have some strings that don't have the | character, you will want to do this instead:
=LEFT(B1,FIND("|",B1&"|")-1)

Excel Workbook
BC
1Single basin|,Double basin|,Triple basin|Single basin
2Double handle|,Single handle|,Touchless|Double handle
3Single hole|,Two holes|,Three holes|,Four holes|,Single hole with deck plate|Single hole
4Single BasinSingle Basin
Sheet1
 
Upvote 0

Forum statistics

Threads
1,216,108
Messages
6,128,872
Members
449,475
Latest member
Parik11

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