Thread: Remove Spaces
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Glenn Ray[_3_] Glenn Ray[_3_] is offline
external usenet poster
 
Posts: 34
Default Remove Spaces

Use the Replace function:
tmpName = Replace(Application.ActiveWorkbook.Name," ","",1)

-Glenn Ray


"Ronbo" wrote:

In a routine i have tmpName that is a temporary workbook name that is used
in the routine to open other workbooks. I need to remove spaces in the
tmpName. Ex. -WorkBook Name = Test One Two.xls - I need the tmpName to be
"TestOneTwo.xls. How do I remove the spaces?

Any help is truly appreciated.

Regards,
Ronbo