Sum not including decimals

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a field [Units] and an unbound textbox that has a control source of
=Sum([Units]). My problem is that if i have two unit value [Units] = 1.3 and
[Units]=1.4 the result of Sum([Units]) is 2.0. The format of both textboxes
is Standard and decimal places is set to 1. Any suggestions? Thank you.
 
Edward said:
I have a field [Units] and an unbound textbox that has a control source of
=Sum([Units]). My problem is that if i have two unit value [Units] = 1.3 and
[Units]=1.4 the result of Sum([Units]) is 2.0. The format of both textboxes
is Standard and decimal places is set to 1. Any suggestions? Thank you.


Try setting the sum text box's Format to 0.000000

If that doesn't provide any additional information, then
investigae where the values are coming from and how they are
getting to the form.
 
If i change the format of the text boxes with SUM([FieldName]) the result is
alway X.00...0. However if i do a DSUM on the same [FieldName] from the same
source table the rusult has X.XX. I am displaying [FieldName] in the detail
of the form and the Sum fields are in the form footer. The format of the
displayed [FieldName] text boxes seem to have no effect on the sum fields.
Hope that gives a little more information. Thank you.

Marshall Barton said:
Edward said:
I have a field [Units] and an unbound textbox that has a control source of
=Sum([Units]). My problem is that if i have two unit value [Units] = 1.3 and
[Units]=1.4 the result of Sum([Units]) is 2.0. The format of both textboxes
is Standard and decimal places is set to 1. Any suggestions? Thank you.


Try setting the sum text box's Format to 0.000000

If that doesn't provide any additional information, then
investigae where the values are coming from and how they are
getting to the form.
 
The detail text box bound to the Units field displays
correctly, but the Sum text box does not??? That is very
strange.

Since the DSum works, I would suspect the form's record
source query is doing something to truncate the value in the
field.

But if the field is displayed correctly in the detail
section, I have to come back to something about the footer
text box or its =Sum expression.

Feels like we're running in circles here ;-)
--
Marsh
MVP [MS Access]


Edward said:
If i change the format of the text boxes with SUM([FieldName]) the result is
alway X.00...0. However if i do a DSUM on the same [FieldName] from the same
source table the rusult has X.XX. I am displaying [FieldName] in the detail
of the form and the Sum fields are in the form footer. The format of the
displayed [FieldName] text boxes seem to have no effect on the sum fields.

Edward said:
I have a field [Units] and an unbound textbox that has a control source of
=Sum([Units]). My problem is that if i have two unit value [Units] = 1.3 and
[Units]=1.4 the result of Sum([Units]) is 2.0. The format of both textboxes
is Standard and decimal places is set to 1.
Marshall Barton said:
Try setting the sum text box's Format to 0.000000

If that doesn't provide any additional information, then
investigae where the values are coming from and how they are
getting to the form.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top