This little UDF will do it for you:
Option Explicit
Function FINDIT(RNG As Range, MyVal As String, _
Optional Delim As String) As String
Dim MyArr As Variant, Itm As Long
If RNG.Cells.Count > 1 Then
FINDIT = "1 cell only"
Exit Function
End If
If Delim = "" Then Delim = ","
MyArr = Split(Trim(RNG), Delim)
For Itm = LBound(MyArr) To UBound(MyArr)
If InStr(MyArr(Itm), MyVal) > 0 Then
FINDIT = Trim(MyArr(Itm))
Exit Function
End If
Next Itm
FINDIT = "Not Found"
End Function
How to install the User Defined Function:
1. Open up your workbook
2. Get into VB Editor (Press Alt+F11)
3. Insert a new module (Insert > Module)
4. Copy and Paste in your code (given above)
5. Get out of VBA (Press Alt+Q)
6. Save as a macro-enabled workbook
The function is installed and ready to use.
========
How to Use:
If the long text string is in A1, in an adjacent cell like B1 enter this formula:
=FINDIT(A1, "University", ",")
The function will return whichever substring within the long string holds the searched value. The substrings are denoted by the delimiter you set in the 3rd value.
Bookmarks