Weird behavior (1 Viewer)

NearImpossible

Registered User.
Local time
Today, 08:44
Joined
Jul 12, 2019
Messages
225
Today when I open a new database that I've been working on for about week, its acting weird.

When I open it, it launches the main page, but when click a button to open a new form, nothing on that forms works unless I open and close the VB editor.

After that, everything on the form works, until I close and reopen the database.

any thoughts?
 

NearImpossible

Registered User.
Local time
Today, 08:44
Joined
Jul 12, 2019
Messages
225
Don't know what happened but its working now.

Tried compact and repair several times with no luck. Made a copy of the database, no luck

Not wanting to have to start from scratch as there are about 100 lines of code on that form, I made a copy of the form to start digging into it line by line. Just for the heck of it, I clicked the button to launch the original form and it loaded correctly.

I've closed and reopened the database about 10 times and its working correctly.

Not sure how making a copy of a form fixed the original, but its working.....
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 08:44
Joined
Feb 28, 2001
Messages
27,002
The answer to the implied question is possible code corruption caused by a "ragged save" that didn't save everything correctly. In general, when editing things, you should be sure that you don't have anything else active in the background (like timers on a different open form). I know we sometimes take shortcuts in editing, but you should always save from an idle application. You should also always make a backup copy if you are going to do a Compact & Repair (C&R) after a long sequence of editing. And the C&R is probably not a bad idea if you are editing complex code or forms or reports, because editing objects like that tends to add "bloat" (wasted unreclaimed space) to your DB and the only way to do the reclamation is a C&R.
 

Users who are viewing this thread

Top Bottom