Removing trailing spaces.

  • Thread starter Thread starter Steven Brobst
  • Start date Start date
S

Steven Brobst

I have a row of cells that may or may not have a trailing
space after the text. Is there a way to test for a space
as the last character, and then remove it if present?
 
In a row next to this one put (i'll assume this row starts in A1)
=TRIM(A1)
copy down
select the new row and paste special values

Dan E
 
Just in case you imported from HTML you might need
to substitute the char(160) with "" like this

=SUBSTITUTE(A1,CHAR(160),"")
 
Thanks for answering that everyone.
Talk about a Doh!!! as I went through all the text
functions and didn't even think about trim as it said
somthing like "between worrds". :)

Steven
 
Back
Top