Here is situation. I have a rather complicated form (tabs, alot of subforms, etc.) that essentially has to call itself. If the original is frmCust, then the copy is named frmCustLookup (there is some code which looks at the form name and then disallows certain controls; so, for example, the user can’t try to launch another copy of the Lookup form).
I just had just made some extensive changes to the backend, and after finishing all changes to frmCust, I copied it to frmCustLookup (as I had done many times before). However, when frmCustLookup is opened, it presents an parameter entry box for a field that is no longer in the backend. I finally traced it to a combo box which has a Select statement as the rowsource. The problem, however, is that this field is no longer in the SELECT statement!
So, I decompiled, compacted, compiled, compacted the database; but still the parameter box comes up. Now remember, frmCustLookup is an exact copy of frmCust which opens fine!
I finally just created a new database and imported all objects. Now it works.
Apparently there was some bit of query optimization code stuck somewhere in the database that the decompile didn’t get rid of! I’m wondering now if my routine should be changed to: decompile, import to new database, compile.