#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default CSV - text

I have "00012345" in a CSV file. when i open the CSV in excel, it comes up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default CSV - text

The problem is how you are openning the file.

If you double-click the icon or, from Excel, do:
File Open

then Excel tries to "help" you by dropping leading zeros. Instead:

Data Import External Data Import Data

and then tell the Wizard that the field is text. The leading zeros will be
preserved.

Another method is to rename the file something other than .csv
--
Gary''s Student - gsnu200766


"pacificwaters" wrote:

I have "00012345" in a CSV file. when i open the CSV in excel, it comes up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default CSV - text

the users don't want to do the wizard every time and specify that each field
is text. we are working with alot of fields and this becomes very
inconvenient.
any other ways to easily set a global option so that we don't ever have to
perform these steps?

thanks for the reply.


"Gary''s Student" wrote:

The problem is how you are openning the file.

If you double-click the icon or, from Excel, do:
File Open

then Excel tries to "help" you by dropping leading zeros. Instead:

Data Import External Data Import Data

and then tell the Wizard that the field is text. The leading zeros will be
preserved.

Another method is to rename the file something other than .csv
--
Gary''s Student - gsnu200766


"pacificwaters" wrote:

I have "00012345" in a CSV file. when i open the CSV in excel, it comes up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default CSV - text

the users don't want to do the wizard and specify text for each field every
time. we are working with alot of fields and this becomes very inconvenient.
any easier way on setting a global option so that we don't ever have to
perform these steps?

thanks for the reply.


"Gary''s Student" wrote:

The problem is how you are openning the file.

If you double-click the icon or, from Excel, do:
File Open

then Excel tries to "help" you by dropping leading zeros. Instead:

Data Import External Data Import Data

and then tell the Wizard that the field is text. The leading zeros will be
preserved.

Another method is to rename the file something other than .csv
--
Gary''s Student - gsnu200766


"pacificwaters" wrote:

I have "00012345" in a CSV file. when i open the CSV in excel, it comes up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default CSV - text

No.
--
David Biddulph

"pacificwaters" wrote in message
...
the users don't want to do the wizard every time and specify that each
field
is text. we are working with alot of fields and this becomes very
inconvenient.
any other ways to easily set a global option so that we don't ever have to
perform these steps?

thanks for the reply.


"Gary''s Student" wrote:

The problem is how you are openning the file.

If you double-click the icon or, from Excel, do:
File Open

then Excel tries to "help" you by dropping leading zeros. Instead:

Data Import External Data Import Data

and then tell the Wizard that the field is text. The leading zeros will
be
preserved.

Another method is to rename the file something other than .csv
--
Gary''s Student - gsnu200766


"pacificwaters" wrote:

I have "00012345" in a CSV file. when i open the CSV in excel, it comes
up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to
display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?





  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,819
Default CSV - text

In that case open the file in Notepad and do a find and replace
"0 - "'0

pacificwaters wrote:

the users don't want to do the wizard every time and specify that each field
is text. we are working with alot of fields and this becomes very
inconvenient.
any other ways to easily set a global option so that we don't ever have to
perform these steps?

thanks for the reply.


"Gary''s Student" wrote:


The problem is how you are openning the file.

If you double-click the icon or, from Excel, do:
File Open

then Excel tries to "help" you by dropping leading zeros. Instead:

Data Import External Data Import Data

and then tell the Wizard that the field is text. The leading zeros will be
preserved.

Another method is to rename the file something other than .csv
--
Gary''s Student - gsnu200766


"pacificwaters" wrote:


I have "00012345" in a CSV file. when i open the CSV in excel, it comes up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?


  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default CSV - text

If your data is laid out exactly the way each time, you could rename the *.csv
file to *.txt and provide a macro that would open the file so that each field is
treated the way you want it.

Rename the file to .txt and record a macro when you open it and you'll have the
code.

If the format of the file varies, you may not be able to macro-ize it. It would
depend on that variation.

pacificwaters wrote:

I have "00012345" in a CSV file. when i open the CSV in excel, it comes up as
"12345".

WITHOUT adding the apostrophe "'00012345" , how else can i get it to display
the zeros in front of the numbers (because it's text, not numeric)?

and the users don't want to go into format-cells each time. any global
settings for this?


--

Dave Peterson
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
grab cell text from multi-tab workbook, show text in another workb pfa Excel Worksheet Functions 16 August 10th 07 08:50 PM
Sumif text is contained winthin a longer text string in a cell Johnny M[_2_] Excel Worksheet Functions 3 March 21st 07 02:50 PM
Text does not display in "Text boxs" and when wrapping text in a c Esteban Excel Discussion (Misc queries) 1 March 8th 07 11:59 PM
text (3750 char.)truncates with text wrap and row heigh adjusted? Boydster Excel Discussion (Misc queries) 1 May 19th 05 05:59 PM
want to remove all text characters equal to one character in length from text string [email protected] Excel Worksheet Functions 1 April 18th 05 12:25 AM


All times are GMT +1. The time now is 07:34 AM.

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

About Us

"It's about Microsoft Excel"