Results 1 to 4 of 4
  1. #1
    Join Date
    Nov 2019
    Posts
    2

    VBA Code Disappearing

    15+ year MS Access developer with multiple enterprise-level deployed applications.





    1. I have a stable Windows 10-Access 2016 database with front end-back end split.
    2. Working in development front end located on C: drive.
    3. Adding new sub to a new form. (Private Sub Form_Load, no code, just the framework)
    4. Debug > Compile.
    5. Sub disappears.


    Tried:

    1. Compact on Close off.
    2. Perform name AutoCorrect off.
    3. In Module View.
    4. Imported all objects into a fresh database file.
    5. Saved form to a new name.
    6. Deleted form, created brand new form, typed sub in (did not copy).
    7. No "hidden" objects persisting from prior/deleted versions of the form.
    8. There is no violation of max file size (19 MB), object count, etc.


    I've seen Access do some truly stupid sh*t (Query '' corrupt 3340 anyone?) but this has me completely stumped.

  2. #2
    Join Date
    Nov 2019
    Posts
    2

    OMFG You're Joking ...

    Solution found.

    Reboot.

    REBOOT???

    R.E.FFFFF.ING.BOOT!!!?????

    Are you kidding me Microsoft?

  3. #3
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    4,290
    Next time it happens, try each of the following
    a) Decompile
    b) Check for available connections
    Colin (Mendip Data Systems) : Website, email
    If this has helped, please click the star button and leave a comment

  4. #4
    apr pillai's Avatar
    apr pillai is offline Competent Performer
    Windows 10 Access 2007
    Join Date
    May 2010
    Location
    Alappuzha, India
    Posts
    186

    VBA Code Disappearing

    Quote Originally Posted by isladogs View Post
    Next time it happens, try each of the following
    a) Decompile
    b) Check for available connections
    Empty Subs will be removed by compiler. Add a Rem line in the middle like: 'x or simply ' symbol alone.

    Or enable the Form_Load Event from Class Object llike: frm.OnLoad = "[Event Procedure]" from Class Object Subroutine.

    https://www.msaccesstips.com/2019/05...and-event.html

    Sent from my iPhone using Tapatalk
    Last edited by apr pillai; 11-20-2019 at 09:25 PM. Reason: For adding a link

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

Similar Threads

  1. Disappearing Form
    By hinchi1 in forum Access
    Replies: 4
    Last Post: 06-12-2018, 05:54 AM
  2. Access 2007 - VBA code disappearing
    By ssissons in forum Programming
    Replies: 8
    Last Post: 10-01-2014, 12:29 PM
  3. Disappearing Act
    By CementCarver in forum Forms
    Replies: 4
    Last Post: 09-04-2013, 03:08 PM
  4. disappearing combo box value
    By j6sander in forum Forms
    Replies: 5
    Last Post: 09-11-2012, 10:22 AM
  5. The amazing disappearing VBA code
    By Michele Keck in forum Forms
    Replies: 2
    Last Post: 10-01-2010, 11:44 AM

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 - Senior Forums