Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2005
    Posts
    34

    Unanswered: Anyway to make a timer/delay VBA module?

    It's a little complicated, but I'll try to keep it as simple as possible. I have 6 tables linked to my central database. The code/macro in the central database opens the other 6 databases to copy down the tables locally again with new data. Problem is the one table takes a very long time to download, and the macro in the central database keeps moving on in it's process. In fact, it moves onto the point where it needs to utillize the table that's still being downloading, and thus cannot run the query on it because it's in use (I get an exclusive user mode error because of it). Is there anyway I can do a delay on this thing before it moves on down to the next command in the macro? All I need is for it to kind of hold off on progressing for about 7 minutes and then continue on.

  2. #2
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6

  3. #3
    Join Date
    Nov 2003
    Posts
    1,487
    Basicly, anything done in a Macro can be also done in VBA code.

    Get your macro to run a function..say...WaitTillLoaded()
    Code:
    Function WaitTillLoaded () 
    Do 
    	 '........................................
    	 '...Code for processing table(s)
    	 '........................................
    If Done Then Exit Do
    	 DoEvents
    loop
    End Function
    ahhhh...or something like that.
    .
    Last edited by CyberLynx; 12-24-05 at 03:23.
    Environment:
    Self Taught In ALL Environments.....And It Shows!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •