Available in the LEADTOOLS Imaging toolkit. |
AnimationEnable example for Visual Basic
Note: Also works with Access 95 and 97.
This example loads and plays an animated file. It assumes that the LEAD control has already been sized to the aspect ratio of the image.
' Load all pages of an AVI file.
Lead1.Load "c:\windows\system\wndsurf1.avi", 0, 1, -1
' Set properties for a scaled animation.
Lead1.AutoRepaint = True
Lead1.AutoSetRects = False
' Set the image display size to match the LEAD control.
Lead1.SetDstRect 0, 0, Lead1.ScaleWidth, Lead1.ScaleHeight
Lead1.SetDstClipRect 0, 0, Lead1.ScaleWidth, Lead1.ScaleHeight
' Allow a continuous loop.
Lead1.AnimationLoop = True
' Start the animation.
Lead1.AnimationEnable = True