Calculate null values in forms

chu3w

New member
Local time
Today, 07:30
Joined
Feb 26, 2010
Messages
3
I have a main form and a subform. Both of the forms are pulling information from the same query. The query has a month and a revenue field. The main form pull revenue for the month of January and the subform is filtered to pull revenue for february. On the main form I have a text field that will add revenue for both months together. My Problem is if there is no value for February then it will not add the revenue together. I tried using the nz function that looks like this

=nz([Forms]![MainForm]![Revenue],0) + nz([Forms]![MainForm]![Subform]![Revenue], 0)

This doesn't work
 
Use the IsNull() function. Have a quick read about how to apply it appropriately.
 
Try this........
Nz([Field1]) + Nz([Field2])
 

Users who are viewing this thread

Back
Top Bottom