W
Wim
I am trying to create an unbound report with several subreports on it, each
with its own record source.
On the main report there are textboxes with dates - txtBegin and txtEnd -
that are filled in when the report is opened from a dialog box.
I need to base certain calculations in the subforms on a number that is
presently displayed in another textbox (txtNumberOfCases) on the main form
with record source:
=(DCount("ID";"nameofquery";"[DateIn] Between [txtBegin] And [txtEnd]"))
Up to here everything works fine.
Now I need to have this "number of cases" available in some of the
subreports and that is where I get lost.
I tried creating a text box in a subform with recordsource:
=Reports![nameofmainreport]![txtNumberOfCases]
but it returns 0.
However, if I put the same text box with the exact same record source on the
main report, it returns the correct number.
Who helps me solving the mystery?
with its own record source.
On the main report there are textboxes with dates - txtBegin and txtEnd -
that are filled in when the report is opened from a dialog box.
I need to base certain calculations in the subforms on a number that is
presently displayed in another textbox (txtNumberOfCases) on the main form
with record source:
=(DCount("ID";"nameofquery";"[DateIn] Between [txtBegin] And [txtEnd]"))
Up to here everything works fine.
Now I need to have this "number of cases" available in some of the
subreports and that is where I get lost.
I tried creating a text box in a subform with recordsource:
=Reports![nameofmainreport]![txtNumberOfCases]
but it returns 0.
However, if I put the same text box with the exact same record source on the
main report, it returns the correct number.
Who helps me solving the mystery?