Bobbinbobwhite
Registered User.
- Local time
- Today, 15:48
- Joined
- Jan 24, 2017
- Messages
- 17
I have a bound parent form with a bound sub-form embedded. All created with the Access 2010 wizard. I have created 2 audit modules to track new, edit & deleted transactions on the sub-form.
I have added before update, on delete and after Del Confirm events to the sub-form. When I open the sub-form and enter, edit or delete data the module runs perfectly. However when I open the parent form with the sub-form embedded, the events do not work. I either get an error that the operation is not supported by this type of object or the module is unable to find the key field on the sub-form, or no errors but the audit table is not updated.
I use these events on some other forms, without a sub-form embedded, and they work fine. I am sure I am missing an important piece of info on how sub-forms work.
Any suggestions on how to resolve my issue? I would consider myself a beginner with VBA, but pretty comfortable with Access. Most of the VBA code I have for the audit tracking is from on-line posts and a lot from this forum. As far as using the Debug in the VBA window of access, it doesn't trigger when the module is called and I haven't been able to figure out how to use it for a called procedure.
Thank you in advance for all of your help!!
I have added before update, on delete and after Del Confirm events to the sub-form. When I open the sub-form and enter, edit or delete data the module runs perfectly. However when I open the parent form with the sub-form embedded, the events do not work. I either get an error that the operation is not supported by this type of object or the module is unable to find the key field on the sub-form, or no errors but the audit table is not updated.
I use these events on some other forms, without a sub-form embedded, and they work fine. I am sure I am missing an important piece of info on how sub-forms work.
Any suggestions on how to resolve my issue? I would consider myself a beginner with VBA, but pretty comfortable with Access. Most of the VBA code I have for the audit tracking is from on-line posts and a lot from this forum. As far as using the Debug in the VBA window of access, it doesn't trigger when the module is called and I haven't been able to figure out how to use it for a called procedure.
Thank you in advance for all of your help!!