HELP! Split text with Excel funcions

gio123bg

Active Member
Joined
Feb 14, 2004
Messages
255
Hi All,
I' m trying to split this text (3 data with "*" as separator).

(blanks)AAAA(blanks)*(blanks)BBBB(blanks)*(blanks)CCCCCC


Let's suppose to have this text in cell B4

In cell B5 I have set this formula (to have only value AAAA) first field in a different column

=LEFT(TRIM(B4);SEARCH("*";B4))

In cell B6 I have set this formula (to have only value BBBB) second field in a different column

=TRIM(MID(TRIM(B4);SEARCH("*";TRIM(B4))+2;LEN(TRIM(B4))))

But +2 or +1 must not be set because the number of blanks is not defined

In cell B7 (last column for the split) .... I need Help.

Any suggestion for a different way to solve my problem will be well appreciated.

Thanks in advance for your kind support.

Regards,

Giovanni
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.

Forum statistics

Threads
1,224,889
Messages
6,181,608
Members
453,055
Latest member
cope7895

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