View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Removing Spaces within text

select the range of cells and do
Edit=Replace

What: put in a space (hit the space bar once)
With: leave blank

Click replace all.

If you need a macro, turn on the macro recorder while you do it manually.

--
Regards,
Tom Ogilvy

"KAREN27" wrote in message
...
Hi All,

I need to write some code to solve this problem.

I have a column of entries that I need to search through, and if it finds
any cells that have entries with a space - then remove the space and join
together the text on either side of the space.

For example:

abc123
def 456
ghi 789 jkl

... the result in the column would then be

abc123
def456
ghi789jkl

Thanks very much for your help
Karen