Results 1 to 7 of 7
  1. #1
    jo15765's Avatar
    jo15765 is offline Expert
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2010
    Location
    6 Feet Under
    Posts
    670

    Keep UI From Freezing

    I am using access 2016 (finally with the times!)

    i have a form that has a button press that will run multiple procedures
    om the button press if like to set a text box to visible and write updates to the text box to update the user of the progress

    ehat currently happens is the UI freezes and goes white until the process is completely finished

    is there a way in access 2016 to provide updates to the user like I am wanting?

  2. #2
    CJ_London is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,397
    you will only be able to update the textbox between running each procedure

    suggest have a function along these lines which you call before or after the procedure (recommend before so if you get an error you know which procedure caused it).

    Code:
    function updateProgress(s as string)
    
    forms!myform!progresstextbox=s & vbcrlf & progresstextbox
    doevents
    
    end function
    if your textbox is deep, this will show completed procedures with the latest one at the top.

  3. #3
    jo15765's Avatar
    jo15765 is offline Expert
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2010
    Location
    6 Feet Under
    Posts
    670
    My current process is form button click event
    Code:
    txtProgress.Visible = True
    
    DeleteTables
    
    CreateTables
    now on to a public module here
    Code:
    Sub DeleteTables()
    ’update textbox
    ’Delete table 1
    ’update textbox
    ’Delete table 2
    End Sub
    now of course this is not actual code but pseudo code that is not working.

  4. #4
    CJ_London is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,397
    so try my suggestion

  5. #5
    ssanfu is offline Master of Nothing
    Windows 7 32bit Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    @jo15765 - you should be aware that constantly deleting and re-creating tables causes dB bloat.
    It is also a good way to introduce corruption.
    Why don't you create the table(s) once and just delete the records??

  6. #6
    jo15765's Avatar
    jo15765 is offline Expert
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2010
    Location
    6 Feet Under
    Posts
    670
    Quote Originally Posted by ssanfu View Post
    @jo15765 - you should be aware that constantly deleting and re-creating tables causes dB bloat.
    It is also a good way to introduce corruption.
    Why don't you create the table(s) once and just delete the records??
    Thank you for that information! I'll create the tables manually and truncate as needed and do inserts as needed.

    I've also become aware that part of the freezing issue is when vba tries to read from the SharePoint table and authentication is required. Can VBA "read" when authentication is required and I can exit my routtine and notify the user of such? Instead of just having access freeze up completely and require a force reboot?

  7. #7
    ssanfu is offline Master of Nothing
    Windows 7 32bit Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    I'll back out at this point. I've never even looked at SharePoint.
    I may be wrong, but somewhere I think I saw that Microsoft was dropping support for SharePoint..... so I never investigated any further.

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

Similar Threads

  1. Replies: 5
    Last Post: 01-24-2014, 01:36 AM
  2. Scroll Detail While Freezing Header
    By EddieN1 in forum Forms
    Replies: 2
    Last Post: 02-03-2013, 08:34 PM
  3. Freezing Access Database
    By snoopy in forum Programming
    Replies: 3
    Last Post: 10-09-2012, 09:09 PM
  4. Replies: 3
    Last Post: 06-05-2012, 01:47 PM
  5. The Problem: Form Keeps Freezing
    By BuzzBamm101 in forum Forms
    Replies: 4
    Last Post: 09-15-2011, 12:07 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