Link to home
Start Free TrialLog in
Avatar of mastiSoft
mastiSoft

asked on

animated gif in WPF

Hi, do anyone have any idea how to use animated gif in WPF application.
ASKER CERTIFIED SOLUTION
Avatar of Chinmay Patel
Chinmay Patel
Flag of India 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 mastiSoft
mastiSoft

ASKER

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 .
Wpf animation is not that hard. Tell me are you using MahApps framework? Or plain Wpf forms?
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 ).
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.
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.
Thank you ))
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.
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.
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.