I would like to use the DCount function if possible, to compare the number of null values for a field with the number in a field in another table. For example:

NameID FieldA
2 x
3 x
3 x

Would yield a count of 2 for NameID2 and a count of 1 for NameID3.

NameID FieldX
2 3
3 2

I would like the comparison to go like:
If Dcount (null values in FieldA) <> value in FieldX then do this…..
This DCount needs to be used for multiple records (many different NameID’s).
Can this be done and if so, what would the DCount function look like and how could I set it up in my VB code?
TIA Eric