Removing Spaces from Text

  • Thread starter Thread starter Satyajit Bhagwat
  • Start date Start date
S

Satyajit Bhagwat

Hello Everybody,

I have a table of numbers where each number is preceded by a space. This
makes the content seem as "Text" to Excel. However, I want to convert this
text in to proper "Numbers" so that I can perform some operations on them.

I tried using a macro to do the job. However, on running the macro, the
values of the cells are also modified. This is not the desired result.

Anybody who knows of a solution, please help me.

Hopefully,

Satyajit Bhagwat
 
Hi

A couple of things to try - using a helper column alongside your existing
data.

=VALUE(A2) might do the trick or
=VALUE(MID(A2,2,LEN(A2)-1) may be needed.
 
Another way if you need to do it again...

Select your range of offending cells.
edit|replace
what: (space bar)
with: (leave blank)
replace all.

It might be quicker than formulas.
 
Back
Top