Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are the benefits of using WPF over Windows Forms? [closed]

Tags:

winforms

wpf

I have previously written user interfaces using .NET and Windows Forms.

I'm about to start development on a new piece of software. This software is just a simple utility which will make use of Rich Text fields, a few buttons, dialog boxes, etc.

It seems Windows Forms is ideally suitable for this. I don't need anything flashy.

However, WPF is something new, and I'd like to learn it.

I made a hello world application in WPF, and I'm not happy, because it takes way too much time to run the application and double that amount of time to compile it.

I'm new to WPF, so I have more than one question:

  1. What sort of applications is WPF suitable for?
  2. What is the future of Windows Forms?
  3. What is the current version of WPF? I guess it's 1.0 since it came with NET framework 3.0.
  4. Will there be any major improvements in the next release of WPF on the things I found while making my first Hello World WPF application?
  5. Is WPF being updated together with NET 4.0 (I mean, the next version will come with .NET v4)?
like image 994
Ivan Prodanov Avatar asked May 22 '09 13:05

Ivan Prodanov


People also ask

Is WPF better than Windows Forms?

The single most important difference between WinForms and WPF is the fact that while WinForms is simply a layer on top of the standard Windows controls (e.g. a TextBox), WPF is built from scratch and doesn't rely on standard Windows controls in almost all situations.

What is the difference between WPF and Windows Form application in C#?

The abbreviation W.P.F simply refers to Microsoft's Windows Presentation Foundation, and WinForms is a simple concatenation of Windows Forms Applications. These are both Microsoft's Windows Applications Graphical User Interfaces that developers may use to develop Windows desktop applications.


2 Answers

See: https://stackoverflow.com/questions/713193/wpf-vs-windows-forms/713249#713249

To answer your questions:

  1. WPF can be used for any type of application, but it really shines in applications that make extensive use of 3D, video, animations, databinding against XML
  2. Nobody knows for sure, but Windows Forms will definitely be around for a while. Microsoft did not build WPF to replace Windows Forms.
  3. The current version is WPF 3.5 SP1
  4. They're going to introduce new controls (an Office-like Ribbon Control, DataGrid and more), improve performance, and more enhancements. See also: .NET 3.5 Client Product Roadmap.
  5. Yes, I believe so.
like image 88
Razzie Avatar answered Sep 18 '22 22:09

Razzie


It took me a while to get into WPF, but I think the area it really shines in is databinding. With very little effort, I was able to get rid of an enormous amount of display logic and let .NET handle all of it. This is a huge win if you are displaying a lot of data. I don't think it's necessarily worth it if all you're doing is passing a couple of parameters and pressing a button.

like image 36
Steve Avatar answered Sep 20 '22 22:09

Steve