take out a string

harisonford

New Member
Joined
May 27, 2011
Messages
17
how to take out a string

4,,,,y,5,,,,,,y,6,,,,,,,,,,,z
i want to take out all what
is between 5&y including 5&y
same for 6&z same for 4&y with one
formula regardless of the number of charactors in each ,just 5&y and anything in between,means the first number and the last number and anything in between regardless of the number of characters ,with one formula every time,and out them in a new cell of course
 

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.
<br /><table cellpadding="2.5px" rules="all" style=";background-color: #FFFFFF;border: 1px solid;border-collapse: collapse; border-color: #A6AAB6"><colgroup><col width="25px" style="background-color: #E0E0F0" /><col /><col /><col /><col /></colgroup><thead><tr style=" background-color: #E0E0F0;text-align: center;color: #161120"><th></th><th>A</th><th>B</th><th>C</th><th>D</th></tr></thead><tbody><tr ><td style="color: #161120;text-align: center;">1</td><td style="font-weight: bold;;">Data</td><td style="font-weight: bold;;">Result</td><td style="font-weight: bold;;">Start Char</td><td style="font-weight: bold;;">End Char</td></tr><tr ><td style="color: #161120;text-align: center;">2</td><td style=";">4,,,,y,5,,,,,,y,6,,,,,,,,,,,z </td><td style=";">4,,,,y,,6,,,,,,,,,,,z </td><td style="text-align: center;;">5</td><td style="text-align: center;;">y</td></tr><tr ><td style="color: #161120;text-align: center;">3</td><td style=";">4,,,,y,5,,,,,,y,6,,,,,,,,,,,z </td><td style=";">4,,,,y,5,,,,,,y, </td><td style="text-align: center;;">6</td><td style="text-align: center;;">z</td></tr><tr ><td style="color: #161120;text-align: center;">4</td><td style=";">4,,,,y,5,,,,,,y,6,,,,,,,,,,,z </td><td style=";">,5,,,,,,y,6,,,,,,,,,,,z </td><td style="text-align: center;;">4</td><td style="text-align: center;;">y</td></tr></tbody></table><br /><br /><table cellpadding="2.5px" rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: #FFFFFF" ><tr><td style="padding:6px" ><b>Worksheet Formulas</b><table cellpadding="2.5px" width="100%" rules="all" style="border: 1px solid;text-align:center;background-color: #FFFFFF;border-collapse: collapse; border-color: #A6AAB6"><thead><tr style=" background-color: #E0E0F0;color: #161120"><th width="10px">Cell</th><th style="text-align:left;padding-left:5px;">Formula</th></tr></thead><tbody><tr><th width="10px" style=" background-color: #E0E0F0;color: #161120">B2</th><td style="text-align:left">=LEFT(<font color="Blue">A2,FIND(<font color="Red">C2,A2</font>)-1</font>)&MID(<font color="Blue">A2,FIND(<font color="Red">D2,A2,FIND(<font color="Green">C2,A2</font>)</font>)+1,999</font>)</td></tr><tr><th width="10px" style=" background-color: #E0E0F0;color: #161120">B3</th><td style="text-align:left">=LEFT(<font color="Blue">A3,FIND(<font color="Red">C3,A3</font>)-1</font>)&MID(<font color="Blue">A3,FIND(<font color="Red">D3,A3,FIND(<font color="Green">C3,A3</font>)</font>)+1,999</font>)</td></tr><tr><th width="10px" style=" background-color: #E0E0F0;color: #161120">B4</th><td style="text-align:left">=LEFT(<font color="Blue">A4,FIND(<font color="Red">C4,A4</font>)-1</font>)&MID(<font color="Blue">A4,FIND(<font color="Red">D4,A4,FIND(<font color="Green">C4,A4</font>)</font>)+1,999</font>)</td></tr></tbody></table></td></tr></table><br />
 
Upvote 0

Forum statistics

Threads
1,224,518
Messages
6,179,253
Members
452,900
Latest member
LisaGo

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