View Single Post
  #3   Report Post  
Biff
 
Posts: n/a
Default Remove leading space

Hi!

Maybe those leading spaces aren't your standard leading spaces, char 32!
They may be some other unseen character like the dreaded char 160.

Try finding out what the actual characters are. Use this formula in a
temporary helper column:

=CODE(B2)

Once you know what those characters are then they should be fairly easy to
get rid of using either EditReplace or, maybe a formula like:

=MID(B2,2,255)

Or:

=SUBSTITUTE(B2,LEFT(B2),"")

Then you could convert the formulas to constants by doing a CopyPaste
SpecialValues. Then deleting the original data.

Biff

"Karidre" wrote in message
...
I wonder if someone can help me with this...it's driving me crazy.

I need to delete a leading space from multiple cells, 200 or more. The
leading space is in front of text that is often more than one word so I
can't
just copy into Word and do a find and replace on the spaces.

I looked in many places for help and found out about the Trim function but
when I tried it, it didn't work for me. Am I doing it wrong? I created a
column next to the column that I want to remove the leading spaces from.
then
I put =TRIM(B2) in the first cell, =TRIM (B3) in the next one, etc. But
all
it did was put the exact same thing as before (with the leading space
still
in it) in that column?

Any suggestions? Thanks!

- Kari