A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Importing Long Numbers as Text cells



 
 
Thread Tools Display Modes
  #1  
Old March 11th, 2010, 02:46 PM posted to microsoft.public.excel.misc
Steve
external usenet poster
 
Posts: 2,662
Default Importing Long Numbers as Text cells

I want to import a text file with some long numbers (16 characters and more).
Excel automatically converts them to floating point numbers which causes it
to lose some digits of precision. When I put quotes around the numbers excel
treats it as text but leaves the quotes around the number and removing the
quotes causes it to covert to floating point even if the format for the cell
is TEXT. If during the import I specify the columns as TEXT everything is
fine. However I need to do this for many files and many columns and I need
do the process many times on an on going basis. Is there anyway to automate
this?
--
Steve
  #2  
Old March 11th, 2010, 03:20 PM posted to microsoft.public.excel.misc
Dave Peterson
external usenet poster
 
Posts: 19,791
Default Importing Long Numbers as Text cells

If the layout of the data is always the same, then you could record a macro when
you do it once and rerun it for all the other files.

If you need help modifying the code, post back with your question and I bet
you'll get help.

Steve wrote:

I want to import a text file with some long numbers (16 characters and more).
Excel automatically converts them to floating point numbers which causes it
to lose some digits of precision. When I put quotes around the numbers excel
treats it as text but leaves the quotes around the number and removing the
quotes causes it to covert to floating point even if the format for the cell
is TEXT. If during the import I specify the columns as TEXT everything is
fine. However I need to do this for many files and many columns and I need
do the process many times on an on going basis. Is there anyway to automate
this?
--
Steve


--

Dave Peterson
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


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


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