petroj02
10-19-2016, 12:04 AM
Hello all,
I have 30 Pictures saved on Server and I want to Switch These 30 Pictures after one second at Frame.picture after click on command button. so far so good but Problem is that sometimes my program get stuck and dont load next Picture. And I dont know where is a Problem Could someone help me? there is my code
module
Function waitTime(ByVal miliSeconds As Double)
Application.Wait (Now() + miliSeconds / 24 / 60 / 60 / 1000)
End Function
click Event
Private Sub CommandButton1_Click()
For j = 1 To 30
waitTime (1000)
Frame1.Picture = LoadPicture("V:\CGC_DATA\Images\picture" & j & ".jpg")
Next
End Sub
I have 30 Pictures saved on Server and I want to Switch These 30 Pictures after one second at Frame.picture after click on command button. so far so good but Problem is that sometimes my program get stuck and dont load next Picture. And I dont know where is a Problem Could someone help me? there is my code
module
Function waitTime(ByVal miliSeconds As Double)
Application.Wait (Now() + miliSeconds / 24 / 60 / 60 / 1000)
End Function
click Event
Private Sub CommandButton1_Click()
For j = 1 To 30
waitTime (1000)
Frame1.Picture = LoadPicture("V:\CGC_DATA\Images\picture" & j & ".jpg")
Next
End Sub