+ Reply to Thread
Results 1 to 6 of 6

Custom format to show integer number as decimal with fix amount of decimal digits

  1. #1
    Registered User
    Join Date
    02-04-2013
    Location
    Quito, Ecuador
    MS-Off Ver
    Office365
    Posts
    25

    Custom format to show integer number as decimal with fix amount of decimal digits

    Hi

    Does anyone know how to define a custom format to show an integer number as decimal with fix amount of decimal digits. e.g.:
    • when typing 350 show 0.0350
    • when typing 47.68 show 0.0048

    Thank you

  2. #2
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP, 2007, 2024
    Posts
    16,379

    Re: Custom format to show integer number as decimal with fix amount of decimal digits

    I am not aware of any number format code that will scale a number by 10,000 (4 decimal places). You can use a "," (or whatever your thousands separator is) to scale a numbers by thousands (multiples of 3 decimal places). For example, 350 formatted as 0.000, will display as 0.350. 47.68 with the same number format code will display as 0.048.

    That's the closest number format solution I can see. I do not see an exact solution using only number formatting. Of course, there are ways to use formulas to divide a number by 10,000 then format to show to the nearest 0.0001.

    If it helps, here's the help file that describes all available number format codes (in my early days of learning spreadsheets, this was one of my most frequently referenced help pages): https://support.microsoft.com/en-us/...7-9c9354dd99f5
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  3. #3
    Registered User
    Join Date
    02-04-2013
    Location
    Quito, Ecuador
    MS-Off Ver
    Office365
    Posts
    25

    Re: Custom format to show integer number as decimal with fix amount of decimal digits

    Hi MrShorty

    Thank you for your reply.

    Your idea didn't match what I look for... but based on your suggestion I tried the custom format "#0,0000." ("," decimal separator and "." thousands separator) and 350 is shown as 0,3500.

    Thank you for your reply, it helped

  4. #4
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Custom format to show integer number as decimal with fix amount of decimal digits

    you can try to achieve this by using a formula
    For example, in Excel, you could use the following formula to convert a number to the desired format:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Where A1 is the cell that contains the input number.

    I know this is not what you want but maybe it will help

  5. #5
    Registered User
    Join Date
    02-04-2013
    Location
    Quito, Ecuador
    MS-Off Ver
    Office365
    Posts
    25

    Re: Custom format to show integer number as decimal with fix amount of decimal digits

    Thank you for your suggestion

  6. #6
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 V 2503
    Posts
    13,702

    Re: Custom format to show integer number as decimal with fix amount of decimal digits

    rafo0510,

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

    Also, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.
    Dave

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 4
    Last Post: 07-09-2022, 12:23 PM
  2. Replies: 2
    Last Post: 05-31-2022, 06:03 PM
  3. [SOLVED] integer number to decimal
    By amir0914 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-05-2019, 06:20 AM
  4. [SOLVED] Tweak a custom number format (hiding decimal point)
    By Harribone in forum Excel General
    Replies: 3
    Last Post: 10-04-2014, 12:12 PM
  5. Decimal number changes to integer
    By nickjnford in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-01-2013, 06:32 AM
  6. format number of decimal places to show
    By maacmaac in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-24-2009, 06:24 PM
  7. [SOLVED] Custom Format - show as decimal
    By Heidi in forum Excel General
    Replies: 4
    Last Post: 06-30-2006, 02:10 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1