Results 1 to 2 of 2
  1. #1
    Jrbeene86 is offline Novice
    Windows XP Access 2007
    Join Date
    Mar 2012
    Posts
    12

    Waiting for a web form to reload

    Hey guys,



    I am using a macro in vba to fill out a few web forms for a secure web page we use. These web forms tie to a sql server so the load times vary quite a bit. I want the macro to wait until the page has finished updating after I hit update.

    I've tried this:

    Do
    ' Wait till the Browser is loaded
    Loop Until Obrowser.ReadyState = READYSTATE_COMPLETE

    but that only makes it wait until the page is loaded when the browser first starts up or goes to a different page. I notice that the green status bar at the bottom is active and was wondering If I could use that? Maybe loop until that goes away?

    There are a few buttons that are disabled and maybe I could loop until they are enabled? could that code be something like this?

    Do
    ' Wait till the Browser is loaded
    Loop Until HTMLDoc.All.btnUpdate.Enabled = True


    Thanks so much in advance!

  2. #2
    Jrbeene86 is offline Novice
    Windows XP Access 2007
    Join Date
    Mar 2012
    Posts
    12
    Found it!

    'Waits until the form is loaded
    Do While Obrowser.Busy: DoEvents: Loop
    Do While Obrowser.ReadyState <> 4: DoEvents: Loop

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

Similar Threads

  1. Reload form based on unbound combo box
    By jefflach in forum Forms
    Replies: 6
    Last Post: 10-19-2012, 12:48 PM
  2. ComboBox after update/reload
    By pmac in forum Programming
    Replies: 1
    Last Post: 11-10-2011, 07:16 PM
  3. How can I reload data on a form?
    By MrC in forum Forms
    Replies: 2
    Last Post: 07-21-2010, 02:58 AM
  4. Waiting Time
    By John Southern in forum Reports
    Replies: 4
    Last Post: 05-25-2010, 09:46 AM
  5. Replies: 0
    Last Post: 07-24-2006, 06:31 AM

Tags for this Thread

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