View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default Removing Spaces within text

Use the =SUBSTUTUTE() function:


=SUBSTITUTE(B7," ","") will the remove the spaces in B7, for example

--
Gary's Student


"KAREN27" wrote:

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