Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Leading Zeros and Phone numbers

I have to work on any number of spread sheets that end up having the
leading "Zero" that is "0" removed...

At present I have a sheet with 32K rows of details and phone numbers...
The problem is that where it is a Mobile number the leading "0" has
been removed.

ie. 0404122345 is now 404122345

How do a do a lookup so that I can add / insert a leading "0" where any
of the phone numbers start that with a 4 have a leading 0 inserted?

Have tried to use the Filter function... But this feature appears to not
work in Office 2007, as expected. Select a Number Filter and "Begins
with" 4 ... Always returns Zero results.

Then depending on what format the col is set to, it removes the leading
zero any way...

..... Any one care to provide some training... North side Brisbane..
Office 2003 worked, but I can not get 2007 to play ball. It must be me.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Leading Zeros and Phone numbers

Say the phone numbers are in column A. If a leading zero has been dropped,
then the length of the number will be 9 rather than 10. In B1 enter:

=IF(LEN(A1)=10,A1,"0" & A1) and copy down.

This restores any missing zeros. If you copy column B and
paste/special/value back onto column A, you will have the column correctly
formatted as Text with the correct values.
--
Gary''s Student - gsnu2007j


"mad_dad" wrote:

I have to work on any number of spread sheets that end up having the
leading "Zero" that is "0" removed...

At present I have a sheet with 32K rows of details and phone numbers...
The problem is that where it is a Mobile number the leading "0" has
been removed.

ie. 0404122345 is now 404122345

How do a do a lookup so that I can add / insert a leading "0" where any
of the phone numbers start that with a 4 have a leading 0 inserted?

Have tried to use the Filter function... But this feature appears to not
work in Office 2007, as expected. Select a Number Filter and "Begins
with" 4 ... Always returns Zero results.

Then depending on what format the col is set to, it removes the leading
zero any way...

..... Any one care to provide some training... North side Brisbane..
Office 2003 worked, but I can not get 2007 to play ball. It must be me.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 510
Default Leading Zeros and Phone numbers

Hi

=TEXT(A1,"0000000000")

The formula converts any number to text string at least 10 characters long.
When the number was shorter, leading 0's are added.

Arvi Laanemets


"mad_dad" wrote in message
...
I have to work on any number of spread sheets that end up having the
leading "Zero" that is "0" removed...

At present I have a sheet with 32K rows of details and phone numbers...
The problem is that where it is a Mobile number the leading "0" has been
removed.

ie. 0404122345 is now 404122345

How do a do a lookup so that I can add / insert a leading "0" where any of
the phone numbers start that with a 4 have a leading 0 inserted?

Have tried to use the Filter function... But this feature appears to not
work in Office 2007, as expected. Select a Number Filter and "Begins
with" 4 ... Always returns Zero results.

Then depending on what format the col is set to, it removes the leading
zero any way...

.... Any one care to provide some training... North side Brisbane.. Office
2003 worked, but I can not get 2007 to play ball. It must be me.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I enter NUMBERS with leading zeros In Excel ie 001, 002 ? bobl3517 Excel Discussion (Misc queries) 6 April 3rd 23 02:09 PM
how to convert numbers and delete leading zeros Lori Excel Discussion (Misc queries) 18 January 12th 08 12:45 AM
Leading decimal and zeros in formating numbers DLJames Excel Discussion (Misc queries) 3 November 30th 07 06:43 PM
How do you delete leading zeros from numbers? emronexcel Excel Discussion (Misc queries) 2 March 21st 07 11:00 PM
sort numbers leading zeros l smith Excel Discussion (Misc queries) 2 June 8th 05 02:05 AM


All times are GMT +1. The time now is 01:04 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"