GameHello everybody, I have a 2 Flag pictures. How could I make these Two picture change(rotate) every 5 seconds in the same location. Any help would be great, thanks
Printable View
GameHello everybody, I have a 2 Flag pictures. How could I make these Two picture change(rotate) every 5 seconds in the same location. Any help would be great, thanks
Let's see... try this code. You'll need a timer, picture1 and picture2 with the images of the flags, and an empty picture3 :)
VB Code:
Private Sub Timer1_Timer() Static Pic As Long If Pic = 1 Then picture3.Picture = picture1.Picture Pic = 2 Else picture3.Picture = picture2.Picture Pic = 1 End If End Sub
Basically, every 5 seconds it will toggle Pic between 1 or 2, and based on that show the proper image :)
Hello Jotat98, thank you so much , the code is perfect, thank youQuote:
Originally posted by Jotaf98
Let's see... try this code. You'll need a timer, picture1 and picture2 with the images of the flags, and an empty picture3 :)
VB Code:
Private Sub Timer1_Timer() Static Pic As Long If Pic = 1 Then picture3.Picture = picture1.Picture Pic = 2 Else picture3.Picture = picture2.Picture Pic = 1 End If End Sub
Basically, every 5 seconds it will toggle Pic between 1 or 2, and
based on that show the proper image :)
again :cool: :) :) :)