![]() |
Trim all but the first 5 characters in cell
How would I write the trim to leave only the first five characters in a
column? |
Trim all but the first 5 characters in cell
Dim rng as Range, cell as Range
With Activesheet set rng = Intersect(.usedRange,.columns(5)).Cells End With for each cell in rng cell = Left(cell.Text,5) Next -- Regards, Tom Ogilvy "Annette" wrote in message ... How would I write the trim to leave only the first five characters in a column? |
Trim all but the first 5 characters in cell
that does the trick .. thanks!
"Tom Ogilvy" wrote in message ... Dim rng as Range, cell as Range With Activesheet set rng = Intersect(.usedRange,.columns(5)).Cells End With for each cell in rng cell = Left(cell.Text,5) Next -- Regards, Tom Ogilvy "Annette" wrote in message ... How would I write the trim to leave only the first five characters in a column? |
All times are GMT +1. The time now is 12:42 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com