Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default How do I retain leading zeros in a column of numbers when file op

I need to retain leading zeros in a column of numbers, such as 001001001.
The 00 must be retained when a csv file is opened.

How?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,574
Default How do I retain leading zeros in a column of numbers when file op

Format the cells as text or else as a custom format, say 000000000

Dave
--
Brevity is the soul of wit.


"vontzy" wrote:

I need to retain leading zeros in a column of numbers, such as 001001001.
The 00 must be retained when a csv file is opened.

How?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 620
Default How do I retain leading zeros in a column of numbers when file op

Rename your csv to .txt, use the wizard to open the txt file in Excel, and
format the column to text before you finish the import.
--
David Biddulph

"vontzy" wrote in message
...
I need to retain leading zeros in a column of numbers, such as 001001001.
The 00 must be retained when a csv file is opened.

How?



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default How do I retain leading zeros in a column of numbers when fil

Thanks Dave! I found this solution just after I posted this. I still thank
you for your reply! I only wish this would work when I open the csv file.
As you may know I must first open the file, then change the Cell Format, and
then save it as an XLS File. If I save it as CSV it loses the Cell Format.
I guess this can't be done automatcally when the File is opened. The
original Text File I am opening with Excel has the leading 00's, they are
just lost. Thanks again.

Vontzy


"Dave F" wrote:

Format the cells as text or else as a custom format, say 000000000

Dave
--
Brevity is the soul of wit.


"vontzy" wrote:

I need to retain leading zeros in a column of numbers, such as 001001001.
The 00 must be retained when a csv file is opened.

How?

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default How do I retain leading zeros in a column of numbers when fil

Dave,

Thanks for the response but surprisingly this does not work. My File is in
Text Format, with the leading 00's in the Cell but when I open it with Excel
it automatically drops them. When I use the Wizard to try to get the 00's
back it simply shifts the Cell Data to the left.

I had stumbled onto the solution that Dave F. had provided just after I
posted this and it does work, althougth not when the File is opened from the
Text File.

Thanks again for your Post.

Vontzy

"David Biddulph" wrote:

Rename your csv to .txt, use the wizard to open the txt file in Excel, and
format the column to text before you finish the import.
--
David Biddulph

"vontzy" wrote in message
...
I need to retain leading zeros in a column of numbers, such as 001001001.
The 00 must be retained when a csv file is opened.

How?






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default How do I retain leading zeros in a column of numbers when fil

Actually, the leading 0's aren't lost when you save to your .CSV file. You can
open that file in NotePad and see them there.

They are lost after you re-open the file in excel.

vontzy wrote:

Thanks Dave! I found this solution just after I posted this. I still thank
you for your reply! I only wish this would work when I open the csv file.
As you may know I must first open the file, then change the Cell Format, and
then save it as an XLS File. If I save it as CSV it loses the Cell Format.
I guess this can't be done automatcally when the File is opened. The
original Text File I am opening with Excel has the leading 00's, they are
just lost. Thanks again.

Vontzy


"Dave F" wrote:

Format the cells as text or else as a custom format, say 000000000

Dave
--
Brevity is the soul of wit.


"vontzy" wrote:

I need to retain leading zeros in a column of numbers, such as 001001001.
The 00 must be retained when a csv file is opened.

How?


--

Dave Peterson
  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 620
Default How do I retain leading zeros in a column of numbers when fil

It *does* work, provided that you format the column to text WITHIN THE
WIZARD, BEFORE YOU FINISH THE IMPORT. If you allow it to import as General
or Number, and then try to change to Text afterwards, it's too late, as you
found.
--
David Biddulph

"vontzy" wrote in message
...
Dave,

Thanks for the response but surprisingly this does not work. My File is
in
Text Format, with the leading 00's in the Cell but when I open it with
Excel
it automatically drops them. When I use the Wizard to try to get the 00's
back it simply shifts the Cell Data to the left.

I had stumbled onto the solution that Dave F. had provided just after I
posted this and it does work, althougth not when the File is opened from
the
Text File.

Thanks again for your Post.

Vontzy

"David Biddulph" wrote:

Rename your csv to .txt, use the wizard to open the txt file in Excel,
and
format the column to text before you finish the import.
--
David Biddulph

"vontzy" wrote in message
...
I need to retain leading zeros in a column of numbers, such as
001001001.
The 00 must be retained when a csv file is opened.

How?






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
Stop excel from dropping the 0 in the beginning of a number? Rosewood Setting up and Configuration of Excel 12 April 4th 23 02:12 PM
need to export row as csv file with column e plus .bom as file name rod Excel Discussion (Misc queries) 5 November 2nd 06 03:38 AM
leading zeros when uploading a number from text file mc01234 Excel Discussion (Misc queries) 1 May 18th 06 08:47 PM
Return SEARCHED Column Number of Numeric Label and Value Sam via OfficeKB.com Excel Worksheet Functions 23 January 30th 06 06:16 PM
creating a bar graph Johnfli Excel Discussion (Misc queries) 0 October 26th 05 08:16 PM


All times are GMT +1. The time now is 04:57 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"