Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it better to use WPF over Windows Forms?

Tags:

For a brand new application, is it better to use WPF over Windows Forms? I used Windows Forms before but not much WPF. As far as I know, WPF is the successor to Windows Forms, right?

The application is going to host DirectX Windows (not WPF 3D, but Managed DirectX and SlimDX) with lots of custom controls.

EDIT: The application is a 3D related application, editor, such as modo:

Image created using the 3D painting program modo.

like image 972
Joan Venge Avatar asked Mar 12 '09 21:03

Joan Venge


People also ask

Is WPF still relevant 2021?

WPF is still one of the most used app frameworks in use on Windows (right behind WinForms).

What is the need of WPF when we had Windows Forms?

WPF allows developers to create event-driven rich client applications for usage on the Windows operating system. WPF can be used to develop and design both Windows applications and web applications while WinForms can only be used to develop and design Windows applications.

What is replacing WPF?

Universal Windows Platform. Both Windows Forms and WPF are old, and Microsoft is pointing developers towards its Universal Windows Platform (UWP) instead. UWP is an evolution of the new application platform introduced in Windows 8 in 2012.


1 Answers

We dealt with this question about 9 months ago. We decided to go with WPF and so far we're happy with the decision. Yes, there is a learning curve. It's fairly considerable especially coming from WinForms where you have so much to unlearn. I also recommend you have access to a designer otherwise your application will probably look a bit shabby. Also be prepared for some WPF gotchas that will have you spending hours scratching your head saying 'why was this so hard'.

But WPF is a step ahead. The data binding, templating and complete control of how you want your windows to look makes you think that this how WinForms should've been originally.

Oh yes, and be prepared to shell out a couple of dollars for some missing controls. There are a couple of things missing like a Date picker and having checkboxes on tree controls (you can actually template this out, but it's not as simple as winforms in that regard). 3.5 SP1 includes a grid control now, thankfully.

I'm sure I'm missing a bunch more, but that's what I can come up with off the top of my head.

Good luck!

like image 174
billb Avatar answered Oct 10 '22 11:10

billb