I am using a form (FrmPupils) to update a Pupils table.
I am checking the table to prevent duplicate entries (ParentGuardianID and ChildID).
I am checking using 2 fields, both are integers
I am using Dcount
I have tried and changed and chopped and looked everywhere and I have nowhere left to go, so, the statement NOW looks like this (and I apologise because it now doesn't make any sense at all after so many iterations)
If DCount("*", "TblPupils", "[ParentGuardianID] =" &Forms!FrmPupils!ParentGuardianID& AND "[Child_ID] =" &Forms!Frm.Pupils!ChildID") > 0 Then
I send a message
help gratefully appreciated
I am checking the table to prevent duplicate entries (ParentGuardianID and ChildID).
I am checking using 2 fields, both are integers
I am using Dcount
I have tried and changed and chopped and looked everywhere and I have nowhere left to go, so, the statement NOW looks like this (and I apologise because it now doesn't make any sense at all after so many iterations)
If DCount("*", "TblPupils", "[ParentGuardianID] =" &Forms!FrmPupils!ParentGuardianID& AND "[Child_ID] =" &Forms!Frm.Pupils!ChildID") > 0 Then
I send a message
help gratefully appreciated