Results 1 to 4 of 4
  1. #1
    RonL is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Nov 2009
    Location
    NJ
    Posts
    114

    Strange Behavior on Startup

    I've been developing a simple db and recently wrote OnLoad and OnUnload subs for the main (and only) form. When I test during a session, including closing the entire db and restarting, everything works fine. But if I close down Access (2010) itself, then start it up, open the db and open the form, the debugger opens with yellow marker on an assignment statement near the beginning of the OnLoad code. It's as if there's a breakpoint there. But I've cleared all breakpoints. There's no error message, audible or visible! If I continue out of the code, the form comes up normally, and if I close it and reopen, it behaves normally. The problem only occurs once and only after opening Access itself.

    Seems like there's some environmental factor with a glitch. I've tried Compact and Repair with no effect. In VBA, the compile option is greyed out. Why would that be?

    Any help appreciated.



    -Ron

    EDIT - OK, I simply untabbed that line of code, moved it a bit, saved closed and problem gone. What the....?! I had tried decompiling, but that in itself didn't help. And even now, the compile menu option in VBA is greyed out.

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Phantom BreakPoints can be caused by editing the code while the debugger is still running. Usually *importing* the db into a fresh new db will leave the issue behind: http://www.btabdevelopment.com/ts/impnew

  3. #3
    RonL is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Nov 2009
    Location
    NJ
    Posts
    114
    I did edit code while debugging. But I thought that's a feature, not a bug :-)

    Thanks for the tip and link. -Ron

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Glad we could help.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Ubnormal SUM behavior
    By spleewars in forum Forms
    Replies: 1
    Last Post: 04-10-2012, 10:27 AM
  2. List Box Behavior
    By Paul H in forum Forms
    Replies: 2
    Last Post: 01-25-2012, 03:48 PM
  3. Web Form Behavior on Sharepoint
    By Flanders in forum SharePoint
    Replies: 1
    Last Post: 09-12-2011, 03:00 PM
  4. Strange Behavior when Sorting
    By geniass in forum Queries
    Replies: 5
    Last Post: 09-02-2010, 03:53 PM
  5. Replies: 6
    Last Post: 03-17-2010, 10:09 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums