I think you have to include some more parentheses to ensure the order of

calculation.

Division and multiplication occur before addition and subtraction.

Calculations happen within parentheses starting with the inmost set and

progressing outward.

If your expression is

A + B / C

Then the result is B divided by C then add in A. While what you might

want is the sum of A and B divided by C. To get that you need an

expression like

(A + B) / C

A + (B / C)

If I am reading your need correctly, then perhaps your expression should

be

(fncTotalSchoolTime("student",[student_id],"","")-(Sum([Excl])+Sum([Reint])))/

fncTotalSchoolTime("student",[student_id],"","")

John Spencer

Access MVP 2002-2005, 2007-2010

The Hilltop Institute

University of Maryland Baltimore County

The following control sources were cut and pasted here. For some reason

txtA is showing the value of the dividend instead of the value of

dividend/divisor. What might cause this? These controls are in a group

in the report. The sum() values are OK.

txtResult

=fncTotalSchoolTime("student",[student_id],"","")-(Sum([Excl])+Sum([Reint]))/fncTotalSchoolTime("student",[student_id],"","")

Report shows 660

txtDivisor =fncTotalSchoolTime("student",[student_id],"","")

Report shows 660

txtDividend

=fncTotalSchoolTime("student",[student_id],"","")-(Sum([Excl])+Sum([Reint]))

Report shows 637