我有一个MsgBox
在给定秒数后自动关闭的脚本:
Sub Test1()
Dim AckTime As Integer, InfoBox As Object
Set InfoBox = CreateObject("WScript.Shell")
AckTime = 3
Select Case InfoBox.Popup("Click OK or do nothing within 3 seconds.", _
AckTime, "This is your Message Box", 0)
Case 1, -1
Exit Sub
End Select
End Sub
问题是,我希望盒子在不到一秒的时间内关闭,也许是半秒,但是将其更改为.5
,例如,不会做任何事情。事实上,我认为它根本不会关闭。