Thread: Trim Blanks
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
pikus pikus is offline
external usenet poster
 
Posts: 1
Default Trim Blanks

You can use "Application.Sendkeys" to effectively press the keys you'
need pressed, but I'd recomment using the Trim Function. Either:

Application.SendKeys("%T") {%=Alt here}
I've had some wierd results with this one that were cleared up after
added "Application.Wait(1)" after it. Maybe that was just me...

Or:

Cells(1, 1).Value = Trim(Cells(1, 1).Value)

Take your pick. - Piku

--
Message posted from http://www.ExcelForum.com