This is going to sound strange and so it is. The problem is in Access XP.
I have a listbox on a form with the names of various room names for a house. The objective is to have the user double-click any of the room names and that room will be added to a subform that is updated to show the room's addition.
The problem arises when there are no rooms that have been added to the subform. This occurs when the form is first used or after all the rooms have been deleted from the subform.
When any room in the listbox is selected by a double click, Access does not pick up the string text. In the OnDblClick event the value for the listbox is null and a cryptic Access error is displayed. "0 - ".
After clicking ok, the form is available and there are no further problems double clicking to add rooms to the subform.
I am not sure how this happens that a form can get so mucked up. It did on another form as well.
When I built a new form, copying over the controls and then the code behind the controls, replacing the old form, the problem was solved.
I have a concern with Access XP. It is often wanting to 'save changes' to form design and perhaps at times code when no changes have been made.
I may be working in the class module for a form then click on the save button and there are 3 forms in the Save Window. I don't remember making changes to any but one form. This is very distracting! It seems like for the most part, the additional forms to save are ones in design mode but have not been worked with.
Just about any form that I put in design mode, then close is a candidate for the "Save Changes in Design" regardless if they have been changed or not.