Access World Forums

Access World Forums (
-   General (
-   -   [SOLVED] Weird behavior (

NearImpossible 09-08-2019 10:36 AM

Weird behavior
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 09-08-2019 10:44 AM

Re: Weird behavior
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 09-09-2019 05:32 AM

Re: Weird behavior
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.

All times are GMT -8. The time now is 03:48 AM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World