Simple Animation with Visual Basic 2008

This is a simple and very cool animation with VB 2008 ***IMPORTANT*** To make this project work you need these two pics- a bat with its wings and an the other bat with its wings down. To get these pics go the following site After going to the link copy and paste the two pics into a directory (simply a place where u know it is like my pics) Public Clas frmMain Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick Static x As Integer = 5 Static y As Integer = 0 Static flip As Boolean = False If y Mod 2 = 0 Then Me.PictureBox1.Image = My.Resources.bat1_a Else Me.PictureBox1.Image = My.Resources.bat1_b End If if Me.PictureBox1.Left (Greater Then Sign)= 500 Then x = -5 flip = True ElseIf Me.PictureBox1.Left (less Then Sign)= 0 Then x = 5 flip = False End If If flip = True Then Me.PictureBox1.Image.RotateFlip(RotateFlipType.RotateNoneFlipX) End If Me.PictureBox1.Left = Me.PictureBox1.Left + xy += 1 End Sub End Class The next vid that i will make will show how make the naimation move using the arrow keys 🙂


  1. @youwasted5secs It will, it just needs a little different code, very little, I know:vb6vb 2008vb 2010c# 2008c# 2010C++ 2008C++ 2010FoxPro 8FoxPro 9batchGame Makerand a few more languages

  2. @boolykbol Im using 2010 thanks anyway:phe just asked if it worked on 6but 6 and 2008/2010 are different. . different code styles. just to let him know:)

Leave a comment