calculation problems....

F

fiona.innes

hey...

I have a report which displays values in dollars (txtVale) and also an
exchange rate (txtRate) I have added another text box called
txtSterling which calculates the dollar value to pounds ie =([txtVale]/
[txtRate]). I have my report grouped as entries are either arrivals or
depatures, in the footer for the grouping i want to sum up the
converted values and i have in the caluclaution =sum([txtSterling]).
Only problem is when i run the report the calculation
=sum([txtSterling]). gives the wrong answer. Does anyone know why?

Fiona
 
M

Marshall Barton

I have a report which displays values in dollars (txtVale) and also an
exchange rate (txtRate) I have added another text box called
txtSterling which calculates the dollar value to pounds ie =([txtVale]/
[txtRate]). I have my report grouped as entries are either arrivals or
depatures, in the footer for the grouping i want to sum up the
converted values and i have in the caluclaution =sum([txtSterling]).
Only problem is when i run the report the calculation
=sum([txtSterling]). gives the wrong answer. Does anyone know why?


The aggregate functions (Count, Sum, Min, etc) are query
functions. They can only operate on *fields* (columns) in
the report/form record source table/query. They are unaware
of *controls* (text box, etc) on the report/form.

To do what you want, sum an expression like:
=Sum(Vale / Rate)
 

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

Top