Could someone identify why the following simple Dlookup function is giving me errors?
Dim intxy As Variant
Dim intxz As Variant
intxy = Forms!form1!vx
intxz = DCount("[id]", "comments", "[ncrtype] = 'I' & [ncrno] = intxy")
I have tried various syntax adjustments but I get either a type mismatch error or "The object does not contain the automation object intxy"
I have had a look at previous posts for this, but I'm not sure which way to solve this.
Dim intxy As Variant
Dim intxz As Variant
intxy = Forms!form1!vx
intxz = DCount("[id]", "comments", "[ncrtype] = 'I' & [ncrno] = intxy")
I have tried various syntax adjustments but I get either a type mismatch error or "The object does not contain the automation object intxy"
I have had a look at previous posts for this, but I'm not sure which way to solve this.