Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Newsgroup Archive
Excel Newsgroups
Excel Programming
Macro to insert a period for single characters in a string
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
Reply to thread
Message
[QUOTE="Jacob Skaria, post: 6397856"] With your names in ColA; try the below macro Sub Macro() lngLastRow = ActiveSheet.Cells(Rows.Count, "A").End(xlUp).Row For lngRow = 1 To lngLastRow arrData = Split(Range("A" & lngRow), " ") For intTemp = 0 To UBound(arrData) If Len(arrData(intTemp)) = 1 Then arrData(intTemp) = arrData(intTemp) & "." End If Next Range("A" & lngRow) = Join(arrData, " ") Next End Sub If this post helps click Yes [/QUOTE]
Verification
Post reply
Forums
Archive
Newsgroup Archive
Excel Newsgroups
Excel Programming
Macro to insert a period for single characters in a string
Top