Formula Help Please II

How_Do_I

Well-known Member
Joined
Oct 23, 2009
Messages
1,795
Office Version
  1. 2010
Platform
  1. Windows
Where am I going wrong here please... In my workbook there is a lot more text after the word "Attendees:" in cell B3... What I need to extract is "CC 1 (25)"...

Excel Workbook
BC
3Record Type: Conclusion. Former Reference: CC 1 (25). Attendees:CC 1 (25). Attendees:
Sheet1
 

Some videos you may like

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!

silentwolf

Well-known Member
Joined
May 14, 2008
Messages
1,134
Office Version
  1. 2016
Hi,
you could use this custom function.

Code:
Function Attendees(strText As String) As String
    Dim intPos As Integer
    
    intPos = InStr(strText, "CC 1")
    Attendees = Mid(strText, intPos)

End Function
 

Gerald Higgins

Well-known Member
Joined
Mar 26, 2007
Messages
9,115
Do you mean you want to show
CC 1 (25)

and not
CC 1 (25).Attendees:

?

With this type of thing, it's usually best to provide several slightly different examples of what you want to do, so we can establish some kind of general rule for your data.
 

jtakw

Well-known Member
Joined
Jun 29, 2014
Messages
5,381
Office Version
  1. 2016
Platform
  1. Windows
Hi,

As pointed out above, it's best to show a few samples of Possible variations of your Text strings.

Based solely on your Single sample:

<b></b><table cellpadding="2.5px" rules="all" style=";background-color: rgb(255,255,255);border: 1px solid;border-collapse: collapse; border-color: rgb(187,187,187)"><colgroup><col width="25px" style="background-color: rgb(218,231,245)" /><col /><col /></colgroup><thead><tr style=" background-color: rgb(218,231,245);text-align: center;color: rgb(22,17,32)"><th></th><th>B</th><th>C</th></tr></thead><tbody><tr ><td style="color: rgb(22,17,32);text-align: center;">3</td><td style=";">Record Type: Conclusion. Former Reference: CC 1 (25). Attendees: John Doe, Jack Doe, Jane Doe, etc.</td><td style=";">CC 1 (25)</td></tr></tbody></table><p style="width:6.4em;font-weight:bold;margin:0;padding:0.2em 0.6em 0.2em 0.5em;border: 1px solid rgb(187,187,187);border-top:none;text-align: center;background-color: rgb(218,231,245);color: rgb(22,17,32)">Sheet602</p><br /><br /><table width="85%" cellpadding="2.5px" rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: rgb(255,255,255)" ><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: rgb(255,255,255);border-collapse: collapse; border-color: rgb(187,187,187)"><thead><tr style=" background-color: rgb(218,231,245);color: rgb(22,17,32)"><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: rgb(218,231,245);color: rgb(22,17,32)">C3</th><td style="text-align:left">=TRIM(<font color="Blue">LEFT(<font color="Red">SUBSTITUTE(<font color="Green">MID(<font color="Purple">B3,SEARCH(<font color="Teal">"Reference:",B3</font>)+10,99</font>),".",REPT(<font color="Purple">" ",99</font>)</font>),99</font>)</font>)</td></tr></tbody></table></td></tr></table><br />
 

Watch MrExcel Video

Forum statistics

Threads
1,122,539
Messages
5,596,754
Members
414,097
Latest member
FaeFen

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
Top