Hi all,
Hope someone out there can help me.I am tring to make an image controller fly from one point to another point ..But I seem to have problems locating the
following code. All I have is an "image" name=graphic ..What is P2:X or P1.Y ?..Could you make it work...?
thanks
VB Code:
Private Sub Timer1_Timer() Dim speed As Long Dim X As Long Dim Y As Long speed = 10 DistX = p2.X - p1.X distY = p2.Y - p1.Y dist = Sqr(DistX * DistX + distY * distY) Unitx = DistX / dist Unity = distY / dist graphic.Move graphic.Left + speed * Unitx, graphic.Top + speed * Unity End Sub




..Could you make it work...?
Reply With Quote