brian peaper
2022-03-10T19:54:29Z
I am using the Active-X control in an Access 2019 form. I am experiencing an error in a very specific set of circumstances when the Access app is closed using the corner X.
If there is more than one form open in the app and the form containing the iGrid has focus and the Navigation pane is not displayed I am getting an error 'This key is already associated with an element of this collection'
If there is more than one form open in the app and the non-iGrid form has focus Access closes without error.
If the Navigation pane is displayed and the iGrid form has focus and the Navigation pane is displayed Access closes without error.
I am unable to debug the app as I need the Navigation page open to get to the code, so I have put messages into form procedures. Following are my actions and sequence of events:
Open Non-iGrid Form
Open iGrid Form [Deactivate Non-iGrid Form]
Close Access from corner X.
Following sequence:
Unload Non-iGrid Form
Unload iGrid Form
Deactivate iGrid Form
Close Non-iGrid Form
Error - if I select Debug code is displayed momentarily followed by
Close iGrid Form - Access closed

Igor/10Tec
2022-03-11T14:52:29Z
It is a very specific issue. We have never seen such a problem before.

Can you provide a sample to reproduce the problem? Is it possible to reproduce it in a brand new Access database?