Excel User Group
Microsoft Excel blogs, forums, files. Read, ask questions, provide answers.

How to disable auto format

Latest post Thu, May 8 2008 3:30 PM by Nick Hodge. 3 replies.
  • Tue, May 6 2008 10:12 AM

    • ali.syed
    • Top 150 Contributor
    • Joined on Tue, May 6 2008
    • Posts 2
    • Points 42

    How to disable auto format

    Hello All,

    Simple but a little complicated question. I work for a Petroleum Products Lab. The instruments used for analysis export the data to an Excel file. 

    Issue: Excel auto formats 349.0 to 349. This is a big issue because precisions are of high importance in this industry. Please let me how to overcome this problem.

    Thanks a ton.

    • Post Points: 21
  • Wed, May 7 2008 11:58 AM In reply to

    • Nick Hodge
    • Top 10 Contributor
    • Joined on Sun, Dec 23 2007
    • Southampton
    • Posts 234
    • Points 3,866
    • MVP

    Re: How to disable auto format

    Ali

    I don't know of a way that you can do this and retain the 'number' (that is you can format it as text).  It will only strip the .0 off it is is 'insignificant', e.g zero and you can put that back through formatting. That is, it will never strip off a significant digit.

    Surely 349, 349.0, or even 349.00000000000 are the same? But 349.00000000001 is not???

    Regards
    Nick Hodge
    Microsoft MVP, Excel
    Southampton, UK

    • Post Points: 21
  • Wed, May 7 2008 3:00 PM In reply to

    • ali.syed
    • Top 150 Contributor
    • Joined on Tue, May 6 2008
    • Posts 2
    • Points 42

    Re: How to disable auto format

    Thanks for the reply.

    How about a start up template? Is the are a way we can force a marco or something like that to achieve this?

    Please let me know.

    Thanks.

    • Post Points: 21
  • Thu, May 8 2008 3:30 PM In reply to

    • Nick Hodge
    • Top 10 Contributor
    • Joined on Sun, Dec 23 2007
    • Southampton
    • Posts 234
    • Points 3,866
    • MVP

    Re: How to disable auto format

     Ali

    You could import it as text (*.txt or no extension at all) and using the wizard mark the columns you wish to hold as there exact representation as text (it's the third step). Then to convert those to numbers with the correct number of decimals you could read each cell, find the period and then replicate that with a format.

    Bear in mind however that Excel will only store the number as a whole if it has no 'significant' decimals the formatting will show correctly but if you select say 129.0 and look in the formula bar it will show as just 129. That's just how it is in Excel

    Regards
    Nick Hodge
    Microsoft MVP, Excel
    Southampton, UK

    Filed under:
    • Post Points: 5
Page 1 of 1 (4 items) | RSS
Copyright Excel User Group and the relevant contributors, 2008. All Trade Marks acknowledged. This site is a peer-to-peer site and NOT affiliated in any way to Microsoft Corp. All rights reserved.