Results 1 to 4 of 4
  1. #1
    techexpressinc1 is offline Novice
    Windows 7 32bit Access 2010 64bit
    Join Date
    Jun 2017
    Posts
    2

    On the screen how to format a 99.1234 percent without the suffix zeros

    We want the screen to show a percent with up to 4 decimal places, a value can be i.e.: 5.1234%
    But if the value does not have 4 decimals not to show the ending zeros.
    If the value is 5.12% - only show 5.12% not 5.1200%
    If the value is 5.1234% - show 5.1234% not 5.12%
    __


    Table field parameters:
    Type Numeric, Field Size = Single, Format=Percent, Decimal Places=4
    _
    Form Format parameters:
    Format Percent, Decimal Places = 4, shows all 4 but when 5.12 shows 5.1200
    Format Percent, Decimal Places = Auto, when 5.1234 show only 5.12

    Is there a way for this to work?
    Thx
    Russ

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,518
    Try the Format() function:

    ?format(.0512,".0000%")
    5.1200%

    Also note:

    cross posters
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    techexpressinc1 is offline Novice
    Windows 7 32bit Access 2010 64bit
    Join Date
    Jun 2017
    Posts
    2
    Sorry about multi-postings, the reason is because no answer is coming thru.

  4. #4
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    Formatting should not be done on tables but should be kept for viewing only.

    I use a number field on the table and for the form under format property: #.0###%

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Display textbox value with percent format
    By AmanKaur123 in forum Programming
    Replies: 2
    Last Post: 01-18-2017, 11:23 AM
  2. Replies: 3
    Last Post: 01-05-2016, 03:06 AM
  3. Replies: 3
    Last Post: 12-21-2012, 02:27 PM
  4. Replies: 3
    Last Post: 01-27-2012, 12:59 AM
  5. Access 2007: Percent Format Issue
    By diane802 in forum Access
    Replies: 6
    Last Post: 12-30-2009, 10:29 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums