Link to home
Start Free TrialLog in
Avatar of aasikolo
aasikolo

asked on

Add zeroes to text box

Good Afternoon,

I have a query whose output is the source of a form (Table view).  Part of this output is latitude and longitude infomration.  I need to display 6 decimal places, but when there are, say 3 decimal places, that is all that is displayed, no "trailing zeroes."

I've tried setting the "decimal places" property to 6 decimal places, but that doesn't correct the problem.

I appreciate your input.

Thanks,

aasikolo
Avatar of Rey Obrero (Capricorn1)
Rey Obrero (Capricorn1)
Flag of United States of America image

try using format([field],"#.000000")
I think formatNumber maybe an option too..  It has been a while since I have used Access..

Kent
Avatar of aasikolo
aasikolo

ASKER

That works for latitude, but longitude is negative.  Entering the minus sign has no effect with that format, that is, the minus sign isn't displayed.

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Rey Obrero (Capricorn1)
Rey Obrero (Capricorn1)
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I may have the wrong end of the stick here but the following expression gives the right output:

    Format(-123.2345, "#.000000")

As far as I can tell, there's no need to conditionally prefix the "-" character.
this is ridiculuos!!!
aasikolo,
explain why you accepted a comment that was a reproduction of a post at http:#a35300049
I don't know what is going on.  I accepted your last installment as the answer, awarded points, and I get another comment in the mail.

I reopen EE, thought I was awarding the points to you again, and then I apparently awarded the points to JezWalters.

Please advise on how to correct this situation.

thank you.
click on Request Attention above and ask to reopen the thread.
It's normal to accept the first answer that works, so capricorn1's post fits this bill - I was just commenting about a problem with his second post.
In case it is not apparent, I requested that a moderator reopen this thread and am waiting for them to do so in order to proceed.

thank you for your patience.
Let's hope the points get awarded this time