Is it better to use WPF over Windows Forms?

前端 未结 11 1092
谎友^
谎友^ 2020-12-15 05:32

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 Form

11条回答
  •  误落风尘
    2020-12-15 06:25

    For what it's worth, it's 2020, and I have written desktop applications in both WPF using MVVM and Windows Forms. I must say that I do not miss writing boilerplate type of code for WPF, such as classes for Converters, using some sort of event mediator to communicate between views, Commands, etc. Using MVVM Light can help with that problem. I like the clean separation of code in WPF/MVVM, but for small projects, I think the ability to very quickly push out a Windows Forms application cannot be understated. For graphic intensive applications, WPF will perform better than Windows Forms.

    These days, I tend to lean towards web development when possible since the web is available anywhere there's a network connection. Of course, web development typically has a longer product delivery as well. A positive, is that the C# that you already know, can translate to development in ASP.NET.

提交回复
热议问题