My count(*) in subform(called "subsearch") footer works fine and is blank when no records are on the form.
My mainform has a textbox which references the subforms textbox (correctly!) This works fine BUT when the subform is empty (no records), returns an #error.
I have tried iif([SubSearch].[Form]![txtSubformCount]>0,[SubSearch].[Form]![txtSubformCount],null) in the control source to no avail.
I also tried =iif([SubSearch].[Form]![txtSubformCount]=null,null,[SubSearch].[Form]![txtSubformCount])
I have also tried using nz
I just can't get the mainform textbox to display 0 or at least remain blank when the subform contains no records even though the count(*) remains blank on the subform footer
Any ideas?
Thanks
My mainform has a textbox which references the subforms textbox (correctly!) This works fine BUT when the subform is empty (no records), returns an #error.
I have tried iif([SubSearch].[Form]![txtSubformCount]>0,[SubSearch].[Form]![txtSubformCount],null) in the control source to no avail.
I also tried =iif([SubSearch].[Form]![txtSubformCount]=null,null,[SubSearch].[Form]![txtSubformCount])
I have also tried using nz
I just can't get the mainform textbox to display 0 or at least remain blank when the subform contains no records even though the count(*) remains blank on the subform footer
Any ideas?
Thanks
Last edited: