- Katılım
- 14 Kasım 2021
- Mesajlar
- 42
- Excel Vers. ve Dili
- Excell 2010 Türkçe
Merhaba aşağıdaki kodlara ne eklemem gerekiyor döngüyü bir sefer çalışıp bitirmesi userform un kapanması için ?
Private Sub UserForm_activate()
Running = True
Call Animation2
End Sub
Private Sub Animation2()
Dim y As Integer
Dim MyTimer As Double
MyTimer = Timer
Do
On Error Resume Next
UserForm1.Image99.Picture = LoadPicture _
(ThisWorkbook.Path & "\NEWSS\Images\Animation\Pulser\lop\" & y & ".Gif")
Do
Loop While Timer - MyTimer < 1
If y = 100 Then
y = 1
Else
y = y + 1
End If
DoEvents
Loop
End Sub
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
Running = False
End Sub
Private Sub UserForm_activate()
Running = True
Call Animation2
End Sub
Private Sub Animation2()
Dim y As Integer
Dim MyTimer As Double
MyTimer = Timer
Do
On Error Resume Next
UserForm1.Image99.Picture = LoadPicture _
(ThisWorkbook.Path & "\NEWSS\Images\Animation\Pulser\lop\" & y & ".Gif")
Do
Loop While Timer - MyTimer < 1
If y = 100 Then
y = 1
Else
y = y + 1
End If
DoEvents
Loop
End Sub
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
Running = False
End Sub