Adding dots before 1st, 2nd, 3th and 4th names, but only first letter

You just need to replace the part of your routine that only looks at the beginning, to look at all of the words and construct a string.


Edit to show dot after last letter

        S = ""
        If cell.Value <> "" Then
            V = Split(cell.Value, " ")
        For Each W In V
            S = S & Left$(W, 1) & "."
        Next W
        cell.Offset(ColumnOffset:=-1).Value = S
        End If

enter image description here

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top