I'd like to count the numbers in a subform based on set of criteria below AND the count of number of records in the subform. I need them both to display in the main form HTRecord.
1. I only want the records that coincide with the main form "ID".
2. I'd like to only count records that don't have anything in the "LastRackQty" field.
3. I'd like the count to be in the main form and not the subform, shown as "CountOfZeroLastRackQty"
If tried lots of variations of this formula:
=DCount(“LastRackQty","LoadData","ID = forms![HTRecord.ID]" AND “NZ(LastRackQty,0)>0")
LoadData is the name of the Table behind LoadData_Subform
PartData is the name of the table behind the main HTRecord form.
They are link by "ID".
![]()