animated gif in WPF

Hi, do anyone have any idea how to use animated gif in WPF application.
LVL 1
mastiSoftAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Chinmay PatelChief Technical NinjaCommented:
I use https://github.com/XamlAnimatedGif/WpfAnimatedGif/ and it works for me. BTW, any specific reason you want to use animated gifts in your app?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
mastiSoftAuthor Commented:
is it any others file format I can use for animation ? I don't like windows wait cursor and use to use animation during some process which can take a time. I did't use animation in WPF before and found it is very strange that this is so complicated .
0
Chinmay PatelChief Technical NinjaCommented:
Wpf animation is not that hard. Tell me are you using MahApps framework? Or plain Wpf forms?
0
Microsoft Azure 2017

Azure has a changed a lot since it was originally introduce by adding new services and features. Do you know everything you need to about Azure? This course will teach you about the Azure App Service, monitoring and application insights, DevOps, and Team Services.

mastiSoftAuthor Commented:
I use plain WPF forms, I started with WPF for 2 month ago and have to release commercial software next month. That's why I ask so many questions ).
0
Chinmay PatelChief Technical NinjaCommented:
Hi mastiSoft,

My intention was to understand the situation better :) Also I have seen you work on the question along with experts (in other questions as well), so I am sure all experts at EE will love to help you. Send 1000s of questions our way.

If you are using Plain WPF Forms - and I am assuming you are not following any pattern like MVVM then we can take this route to show a progress bar.

I have not used this but I know for sure it works and I believe it is simpler than the complex routes I have taken in past.

https://github.com/charri/Font-Awesome-WPF/blob/master/README-WPF.md#spinning-icons

1. First Install Font-Awesome using Nuget Package Manager
PM> Install-Package FontAwesome.WPF

Open in new window

2. Then Put this code in your Windows Header where namespaces are added.
 xmlns:fa="http://schemas.fontawesome.io/icons/"

Open in new window

3. In your XAML, put this code where you want to show loading/progress
<fa:ImageAwesome Icon="Spinner" Spin="True" SpinDuration="10" />

Open in new window

4. Set the visibility as per your requirements.

Please note that on Experts-Exchange, if you are a premium user, you can take 1:1 help. Many experts provide 1:1 help for free.

Regards,
Chinmay.
0
mastiSoftAuthor Commented:
Thank you very  much for that much information.  I programmed on C++ and VB and C# windows forms before so all this with WPF is new for me now. I will check this with MahApps framework, maybe it is something for me.
Have a nice day
Best regards.
0
mastiSoftAuthor Commented:
Thank you ))
0
Chinmay PatelChief Technical NinjaCommented:
If you have 1 month to release the software I think (I am not sure how big your software is though) you should not spend time in changing to any other framework. MahApps would make your software look really good and it works like a charm but there is a small learning curve.

I am a huge C#/Winforms fan. VB6 too( VB.Net not so much:) ) and coming from that background it took years before I started realizing WPF's full potential. If you have a looming deadline I suggest you not to experiment a lot with WPF and do things the easy way i.e. don't go for MVVM or MahApps for that matter. It will take more time and will leave you frustrated. It is counter productive when you have to deliver results.

Some might think that my advise is not right but speaking from experience, WinForms to WPF migration can add weeks(if not months) to your overall delivery period.

All the best.
0
mastiSoftAuthor Commented:
Thank you, but I have no choice, it was specified as WPF and I cannot do the program in Windows form. VB 6 was my first language ). I'm on the good way to finish the project in time but sure I will post a lot off questions , don't have so much time to investigate all by my self. It is nice to know that there is a people who can help.  
Thank you again.
0
Chinmay PatelChief Technical NinjaCommented:
No problem. Also, I did not mean to say do not use WPF, just avoid trying to adapt to MahApps or any other Framework for that matter. Once you have released the software and everything is under control, you can evaluate if it is wise to adapt to another framework.
1
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
WPF

From novice to tech pro — start learning today.