Tuesday, May 19, 2020

Extract last Word


#Function to split and parse out last word from a sentence in a cell.
#A1 = "This is the last word"
#Output = "word"

Function Laststr(str As String) As String
    LArray = Split(str, " ")
    lastindex = UBound(LArray)
    Laststr = LArray(lastindex)
End Function