TRIM

G

Guest

Move your mouse up near the column header, on the right side. When it changes
into the <-|-> symbol, double click, and Excel will auto-size your column
for you.
 
G

Gord Dibben

Without entering a formula and copying down, try a macro to TRIM the entire
column in place.

Sub TRIM_EXTRA_SPACES()
Dim cell As Range
For Each cell In Selection
If (Not IsEmpty(cell)) And _
Not IsNumeric(cell.Value) And _
InStr(cell.Formula, "=") = 0 _
Then cell.Value = Application.Trim(cell.Value)
Next
End Sub


Gord Dibben MS Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top