By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,659 Members | 911 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,659 IT Pros & Developers. It's quick & easy.

Sum Unbound Control on Continuous Form Footer?

P: n/a
Pat
Hello,
I've used Sum() to total bound fields on a continuous form with no problem.
However, I now have a continuous form, on which I use an unbound field to
calculate the number of hours between two times stored in a record (bound
fields). This field is called txtDuration.

On my footer, I've created another unbound field named txtWeeklyTotal. I've
set the Control Source to =Sum([txtDuration]), but this returns a #Name?
error. I've tried [Me].[txtDuration] and it still doesn't seem to recognize
the unbound field.

Please, someone show me the error of my ways. This has been driving me
crazy for too long.

Thanks, as always!
Nov 12 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Pat wrote:
Hello,
I've used Sum() to total bound fields on a continuous form with no problem.
However, I now have a continuous form, on which I use an unbound field to
calculate the number of hours between two times stored in a record (bound
fields). This field is called txtDuration.

On my footer, I've created another unbound field named txtWeeklyTotal. I've
set the Control Source to =Sum([txtDuration]), but this returns a #Name?
error. I've tried [Me].[txtDuration] and it still doesn't seem to recognize
the unbound field.

Please, someone show me the error of my ways. This has been driving me
crazy for too long.

Thanks, as always!


Since you are using a calculated field to be summed, don't use the name, use the
control souce.

=(Qry*Dollars) is the control source, name is Extended.

For the totals, enter
=Sum(Qty*Dollars)
not
=Sum(Extended)
Nov 12 '05 #2

P: n/a
Pat
Thanks for the reply. The field isn't calculated, as much as it's assigned
in VB. My calculation is done in the form's OnCurrent. The value is then
assigned to the unbound textbox.

Maybe I can compund the calculation in the form's record source query, but
I'll have to wait until tomorrow to try.

Any other suggestions?

"Salad" <oi*@vinegar.com> wrote in message
news:40***************@vinegar.com...
Pat wrote:
Hello,
I've used Sum() to total bound fields on a continuous form with no problem. However, I now have a continuous form, on which I use an unbound field to calculate the number of hours between two times stored in a record (bound fields). This field is called txtDuration.

On my footer, I've created another unbound field named txtWeeklyTotal. I've set the Control Source to =Sum([txtDuration]), but this returns a #Name?
error. I've tried [Me].[txtDuration] and it still doesn't seem to recognize the unbound field.

Please, someone show me the error of my ways. This has been driving me
crazy for too long.

Thanks, as always!
Since you are using a calculated field to be summed, don't use the name,

use the control souce.

=(Qry*Dollars) is the control source, name is Extended.

For the totals, enter
=Sum(Qty*Dollars)
not
=Sum(Extended)

Nov 12 '05 #3

P: n/a
Pat
So, I played around and created the calculation within the underlying query,
instead of on the form. Now, I have no problems using Sum with the Bound
Field.

Thanks for the redirection.
"Pat" <no*****@ihatespam.bum> wrote in message
news:Qt******************@fe1.texas.rr.com...
Thanks for the reply. The field isn't calculated, as much as it's assigned in VB. My calculation is done in the form's OnCurrent. The value is then
assigned to the unbound textbox.

Maybe I can compund the calculation in the form's record source query, but
I'll have to wait until tomorrow to try.

Any other suggestions?

"Salad" <oi*@vinegar.com> wrote in message
news:40***************@vinegar.com...
Pat wrote:
Hello,
I've used Sum() to total bound fields on a continuous form with no problem. However, I now have a continuous form, on which I use an unbound field to calculate the number of hours between two times stored in a record (bound fields). This field is called txtDuration.

On my footer, I've created another unbound field named txtWeeklyTotal. I've set the Control Source to =Sum([txtDuration]), but this returns a #Name? error. I've tried [Me].[txtDuration] and it still doesn't seem to recognize the unbound field.

Please, someone show me the error of my ways. This has been driving me crazy for too long.

Thanks, as always!


Since you are using a calculated field to be summed, don't use the name,

use the
control souce.

=(Qry*Dollars) is the control source, name is Extended.

For the totals, enter
=Sum(Qty*Dollars)
not
=Sum(Extended)


Nov 12 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.