Run-time error '2427': You entered an expression that has no value

S

Stapes

Hi

I am getting this error with this line of code:

If (Me.[Address 2] Like Forms!FM_DeDupe_Customers_Pocd!
DuplicateCustomerSubform!Add2) Or (IsNull(Me.[Address 2])) Or (Me.
[Address 2] = "") Or (IsNull(Forms!FM_DeDupe_Customers_Pocd!
DuplicateCustomerSubform!Add2)) Then

I have traced it to one field:
Forms!FM_DeDupe_Customers_Pocd!DuplicateCustomerSubform!Add2

Which in this instance has nothing in it. There are no records in the
subforms source.

Is there a proper way of dealing with this - i.e: no records in
subforms source - I looked for On No Data, but that property is not
given for the form?

What also baffles me is that there are 2 previous nested if statements
referring to fields on this subform too, which appear to have executed
without an error.

Stapes
 
Top