If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > PC based Database Applications > Microsoft Excel > MsgBox "Updating will take place.." to delay for 10 seconds

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-14-04, 11:59
alienscript alienscript is offline
Registered User
 
Join Date: Jul 2004
Posts: 23
MsgBox "Updating will take place.." to delay for 10 seconds

Hi fellows,

I have the following Workbook_Open event.
If I want the MsgBox "Updating will take place..." to delay for 10 seconds so that a user will be able to decide either click OK or Cancel, how should the code be like ?
Any help is much appreciated. Thanks


Private Sub Workbook_Open()
If ActiveWorkbook.Name = "8800 TSL Change Record( dates sorted).xls" Then
MsgBox "Updating will take place"

Call SortPlt8800TSLchangeRecord
Else
cancel = True
End If
End Sub
Reply With Quote
  #2 (permalink)  
Old 10-14-04, 12:09
shades shades is offline
Registered User
 
Join Date: Oct 2003
Posts: 1,091
Perhaps something like this?

Code:
Sub DelayTest()
Dim i As Integer

For i = 1 To 5

    Sleep 5000 'delay in milliseconds

    MsgBox "Time delayed message loop " & i

Next
End Sub
Change as appropriate.
__________________
old, slow, and confused
but at least I'm inconsistent!

Rich
(retired Excel 2003 user, 3/28/2008)

How to ask a question on forums
Reply With Quote
  #3 (permalink)  
Old 10-14-04, 12:10
shades shades is offline
Registered User
 
Join Date: Oct 2003
Posts: 1,091
Or try this page:

excelfiles
__________________
old, slow, and confused
but at least I'm inconsistent!

Rich
(retired Excel 2003 user, 3/28/2008)

How to ask a question on forums
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On