I don't understand what this line of code does but I'm guessing it automatically saves the current record from my form to the underlying table. When it saves it I do not know.
If that's correct then I'm messing it up somehow by adding 3 extra lines. See below.
The following code works just fine as is but it doesn't work if I take out the three "rem-out" rows of code - why?
It seems to me that it should run the append query in the middle - no problem. The append query works off the table where the data just got acCMDSaved but I'm no programmer. Help.
Private Sub cmdExit_Click()
If Len(Me.PN) > 0 And Len(Me.REV) > 0 And Len(Me.Part_Description) > 0 Then
DoCmd.RunCommand acCmdSaveRecord
'DoCmd.SetWarnings False
'DoCmd.OpenQuery "Q_AppendPNDescER"
'DoCmd.SetWarnings True
Form_F_PartAdds.cboPNAddRev = Me.REV
DoCmd.Close acForm, "F_PartNew"
Else
MsgBox "You must provide a value for PN, Rev, Description"
End If
End Sub