Index or primary key can't contain a Null value. (Error 3058)
This is the message that I get when one of the forms that I have opens. The code that is associated with the command button that opens the form is as follows:
Forms!frmLookup.Visible = False
DoCmd.Close , "frmLookup", acSaveYes
DoCmd.OpenForm "frmlead", acNormal, "", "", acFormAdd, acDialog
I want the form to open in a data entry mode. This form has 2 subforms that are connected to it, and that may be causing this problem. The error occurs when the first field loses its focus after entering a company name.This error pops up twice.
Thank you for your help.
This is the message that I get when one of the forms that I have opens. The code that is associated with the command button that opens the form is as follows:
Forms!frmLookup.Visible = False
DoCmd.Close , "frmLookup", acSaveYes
DoCmd.OpenForm "frmlead", acNormal, "", "", acFormAdd, acDialog
I want the form to open in a data entry mode. This form has 2 subforms that are connected to it, and that may be causing this problem. The error occurs when the first field loses its focus after entering a company name.This error pops up twice.
Thank you for your help.