Re: Nz Function in Control Source
- From: "Phil Stanton" <phil@xxxxxxxxxxxxxxxxxx>
- Date: Fri, 30 May 2008 11:51:10 +0100
Several things
Make sure your total is in the Report Footer, not the page footer
The expression you want is
=Sum(IIf(IsNull([PremiumGBP]),0,[PremiumGBP]))
HTH
Phil
"colin spalding" <colin.mardell@xxxxxxxxxxxxxxx> wrote in message
news:9240f596-c0c7-476b-8a46-d4d127d44dfe@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Access 2003
I subform which lists financial transactions for a client in the main
form, which i total in a textbox named "txtTotalPremium" in the
subform footer with the Control Source "=Sum([PremiumGBP])"; without
quotations of course. This works fine until the subform has no
records to return in which case textbox is blank. That would be fine
except I need to use the figure in another text box on the main form
as part of another calculation. I have tried hundred different
combination of the Nz and IIf functions all to no avail. it seems to
me that the straight forward "=Nz(Sum([PremiumGBP]),0)" should do it,
but unfortunately not; whatever I do I get a blank textbox and
"#Error" and/or #Name?" in the mainform textbox, Where do I go from
here?
.
- Follow-Ups:
- Re: Nz Function in Control Source
- From: colin spalding
- Re: Nz Function in Control Source
- References:
- Nz Function in Control Source
- From: colin spalding
- Nz Function in Control Source
- Prev by Date: Re: Reset subtotal within a query
- Next by Date: Table setting to disallow new rec's?
- Previous by thread: Nz Function in Control Source
- Next by thread: Re: Nz Function in Control Source
- Index(es):
Relevant Pages
|