Removing leading zeros

G

Guest

I have an imported table in an Access database that has a field with leading
zeros.
Some of the data contains 2 or 3 leading zeros but the field length is the
same. How can I trim these leading zeros?
 
G

Guest

Assuming the remainder of the data is numeric, convert it to integer (or
other numeric type) and then back to string:

CStr(Cint(SourceData))

HTH,
Barry
 

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