automation error

Joined
Nov 29, 2013
Messages
1
Reaction score
0
hello
I have a userform to display a warning message that works ok but now after perhaps some windows update give me a error "automation error" .
I know the cause is this userform because when I remove user form the macro works fine
help is welcome
userform code

Code:
Option Explicit
Private Sub ProgressBar1_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal x As stdole.OLE_XPOS_PIXELS, ByVal y As stdole.OLE_YPOS_PIXELS)
End Sub
Private Sub UserForm_Activate()
Dim dTime As Date
Dim i As Integer
For i = 1 To 100 Step 100 / 8
dTime = Now + TimeValue("0:00:01")
Application.Wait TimeValue(dTime)
ProgressBar1.Value = i
Next i
End Sub
Private Sub UserForm_Initialize()
Label3.Caption = Format(Now, "dddd d mmmm yyyy hh:mm:ss")
End Sub
thanks
 
Back
Top