Only remove first digit if it is a "0"

S

Steved

Hello from Steve Dee

Please I would like to only remove first digit if it is a "0" In Col B:B.

Yes their are more digits in a row in Col B:B

Yes some have digit starting at "1" to "9" which I need to stay

Yes their is 1 Character only "X" which I need to stay

I thankyou
 
S

Steved

Hello from Steved

I looked at other answers to my query

=MID(B35,1,LEN(B35))

Thankyou.

ps Can the above be done in VBA please.
 
S

Steved

Hello from Steved

Oops I forgot to check my column, the below does not remove the first "0"

=MID(B35,1,LEN(B35))

Thankyou.
 
R

Rick Rothstein

Assuming the "0" is actually part of the cell's value and not put there by
Cell Formatting, then try this formula...

=MID(B1,1+(LEFT(B1)="0"),99)

and copy it down as needed.
 
S

Steved

Hello Rick

I Thankyou

Steved

Rick Rothstein said:
Assuming the "0" is actually part of the cell's value and not put there by
Cell Formatting, then try this formula...

=MID(B1,1+(LEFT(B1)="0"),99)

and copy it down as needed.
 

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