trimming a space in the middle of a string

T

thomas donino

I have a list of names in one column. I want to trim the space from the
middle so that Jim Jones looks like JimJones. Any help?

Thank You
 
J

Jacob Skaria

VBA solution

Msgbox Replace("Jim Jones",chr(32),"")

If this post helps click Yes
 
S

Sam Wilson

Highlight the column and press Ctrl + H for find & replace - replace " " with
"" (you don't need to type the quotation marks, they're just so you can see
what I've typed)
 
G

Gord Dibben

Since you posted in programming group.

Public Sub Strip_WhiteSpace()
Selection.Replace what:=" ", _
replacement:="", lookat:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False
End Sub


Gord Dibben MS Excel MVP
 
Top