hello there
this is my code
when i press the button i got an error message (Compile error: variable not defined)
any help?
this is my code
Code:
Private Sub cmdSave_Click()
If DCount("P_ID", "tbl_Edbarat_Sanctions_1", "[P_ID] = " & [P_ID]) > 0 Then
'no need to enter the record because it's existed
Else
'we should enter the record because it's not existed
strsql101 = "insert into tbl_Edbarat_Sanctions_1 (P_ID, Memo_Notation_Serial_Number) Values ('" & Me.P_ID & "', '" & Me.txtSerialNumber & "')"
DoCmd.RunSQL strsql101
End If
End Sub
any help?