Put this code in the Before Update envent of your form;
Code:
If IsNull(Me.DataID) Or Me.DataID = "" Then
MsgBox "You have not entered a Data ID", vbInformation, "No Primary Key"
Cancel = True
Me.DataID.SetFocus
End If
DataID is the primary key, set to Number /Required.