Test for no-value in control
Posted on 2001-06-08
I have a report with 2 sub-reports. The report is a customer statement between 2 dates showing his/her orders and payments.
One sub-report shows all orders between the 2 dates, and the other sub-report shows all payments between the 2 dates. On each sub-report there is a non-visible control which is the sum of orders (or payments).
This non-visible control is used to supply the total orders and payments values to controls on the main report.
The controls on the main report have control source as:
[sbrOrders] and [sbrPayments] are the names of the 2 sub-reports. [txtSumOrders] and [txtSumPayments] are the non-visible controls.
A problem occurs when there are no orders (or payments) between the 2 dates. There is no value in the total control on the main report, not even Null.
How do I test for this situation so that I can run alternative code?