remove leading zeros from text strings

G

Guest

I have a long list of text strings and would like to remove leading zeros,
returning each string with zeros removed. Is there an easy way to do this
using excel text functions?

ie. 00234 234
02569 2569 etc
 
G

Guest

If your string is in A1, then =trim(value(a1)) should get it. Value converts
it to a number and therefore drops leading 0's. Trim is my lazy way of
converting back to a string (the text function works also but requires
another argument).
 
N

Niek Otten

=TEXT(VALUE(C9),"#")

Or, if they don't have to remain strings, just

=VALUE(A1)

--
Kind regards,

Niek Otten

Microsoft MVP - Excel
 

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