Command button click crashes access 2007 unless VBA editor is open

haydenal

Registered User.
Local time
Today, 10:15
Joined
Jan 8, 2009
Messages
52
I have a form with 2 buttons. One button is an "exit" button with no customization. The other button is a "search" button that runs a bit of code. Until recently, everything worked fine.

I think they only thing I've changed in my db is that I selected "compact on close."

Now every time I click the "exit" button, it still works fine. When I click the "search" button access crashes. If I open the vba editor and then click "search," it works fine.

I'm not sure where to go with this one. Any thoughts?
 
Seem a logical next step would be to take the compact on close back out and see if it works?
 
I guess I should have mentioned....logical first step complete. :)
 
So does it zonk when you leave it out?
 
Yes it zonked.

Ok, I don't get this. So I made a copy of the form and ran the copy....works fine. Then ran the original form....it worked fine. So then I deleted the copy, closed the database, ran the original again.....works fine. It appears I have a solution, but I don't have any idea why that would resolve the issue. Thoughts?
 
My best guess at this point is there must have been a bit of corruption somewhere that the repair routine couldn't see and your continuous tinkering some how eliminated it...?
 

Users who are viewing this thread

Back
Top Bottom