Link to home
Start Free TrialLog in
Avatar of jaxrpc
jaxrpc

asked on

Animated Gif in Vb.net form

Hi, i am trying to make a monitoring screen to monitor some machines and i am intending to animate the machines when they are in operation and stop animating when they are not in operation. Can i add animated gif to vb.net form and switch between animated gif and non animated gif depending on situations? Or there are better ways of doing this, not necessary using animated gif, all methods are welcome. thanks
ASKER CERTIFIED SOLUTION
Avatar of jjardine
jjardine
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Fernando Soto
Hi jaxrpc;

Have you looked at the ImageAnimator Class in Visual Studio .Net?

Fernando
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of xersoft
xersoft

Building directly on jjardine’s idea:

You could have two picture boxes on your form, each the same size and in the same location. One picture box has it’s image property set to a static non moving image and the other set to the moving gif image.

Then have a procedure that flips the visible property depending on if you want the animated image showing or the static one.


Public property AnimationVisible() as Boolean
Get()
      Return picAnimated.visible
End Get
Set(value as Boolean)
      picAnimated.visible = value
      picUnAnimated.visible = not value
End set
End property

(sorry if the VB syntax is a bit off)