If I copy and paste from HTML, I will get text entries for
"numbers" beginning with zero as Text without the zeros
being stripped off. So it would seem that the HTML that your
are reading from was generated from an Excel spreadsheet
and that they were numbers in the original Excel worksheets
-- in other words you have "round tripping" code in your HTML.
What I posted before still applies. I did not realize that 4 digits
was the entire phone number. You can use a custom format
of 0000 and you could then use the code I mentioned before
changing 5 to 4 and 00000 to 0000
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages:
http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page:
http://www.mvps.org/dmcritchie/excel/search.htm
<(E-Mail Removed)> wrote in message news:0a3c01c3da97$84abe300$(E-Mail Removed)...
>
> >-----Original Message-----
> >"Andy" <(E-Mail Removed)> wrote in
> message
> >news:08a701c3da94$2dd89710$(E-Mail Removed)...
> >> When I paste a list of telephone numbers, any leading
> >> zeros are not displayed. (eg. 0944.. shows as 944...)
> How
> >> can I display them corectly?
> >>
> >> Thanks
> >> Andy
> >
> >Format the cells as text before pasting the data.
> >
>
> Hi Paul
> Unfortunately it doesn't work since the original data is
> in html format and when pasting, Excel defaults back to
> number format. If I change the format back to text after
> pasting, then the zeros are 'lost'. If I choose "paste
> special" and paste as text, then all the data is pasted to
> one column.
> Andy