I am experiencing some inconsistency when coding these Events in Access 2007.
I have a Form "People" that has a subform "Roles". Using the right-click approach, I am deleting Roles from an individual Person. There are occasions when the Form_DeleteEvent is not triggered in the VBA code of the subform and the Form_BeforeDelConfirm Event is executed. I am trying to work out under which circumstances this happens, meanwhile I am wondering if anyone else has a similar experience.
So far, I suspect this sequence maybe due to me Opening the People Form from another Form. This code is included.
Private Sub txtName_DblClick(Cancel As Integer)
If Not (IsNull(txtName) Or txtName = 0) Then
If Application.CurrentProject.AllForms("People").IsLoaded Then _
DoCmd.Close acForm, "People", acSavePrompt
DoCmd.OpenForm "People", , , "ID = " & ID, acFormEdit, acDialog, "Open<"
blnFullForm = False ' Set the indicator for not haing all Navigation controls