Results 1 to 5 of 5
  1. #1
    2 Star Lounger
    Join Date
    May 2005
    Posts
    180
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Trailing decimal in report (2007)

    I have a field in a table that is set to double with 2 decimal points. Sometimes the final decimal is a zero, xxx.x0. There is a difference whether this is reported as xxx.x0 or xxx.x. Can the trailing 1/100th be omitted if its value is zero either in the table or a report based on this table?

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trailing decimal in report (2007)

    You could set the Format property to <code>0.0#</code> or to <code>#,##0.0#</code>

  3. #3
    2 Star Lounger
    Join Date
    May 2005
    Posts
    180
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Trailing decimal in report (2007)

    I've tried your suggestion in both the format property of the table field and the report with no effect.
    More importantly I forgot a very important point. Sometimes xxx.x0 needs to be reported as xxx.x0 and other times as xxx.x. I suspect that I must be able the data in the table with or without the trailing '0'. Is this possible As an example a code of 278.20 may be acceptable or 278.2-they are not considered the same.

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trailing decimal in report (2007)

    If they are codes, you might be better off using a text field. Access cannot distinguish 278.2 and 278.20 as numbers, but in a text field, the values are stored the way they are entered, so "278.2" is different from "278.20".

  5. #5
    2 Star Lounger
    Join Date
    May 2005
    Posts
    180
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Trailing decimal in report (2007)

    Thanks for your quick reply. I know it will work as a text field but was hoping for another solution Thank you

Posting Permissions

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