Back to list
Views:   22.5K
Replies:  1

MVC vs MVP in Windows Forms


I am working on a Windows Forms .NET application (i.e. Winforms).  Is MVC better or should I go with MVP?

Thanks and regards.
Ali Momin, May 18, 2010
Reply 1

First off, the MVP pattern has been retired (here), instead Martin Fowler has separated it into two new patterns called Supervising Controller and Passive View.

I am no expert in these patterns, I have however used Passive view successfully in many WinForms applications and is currently my preferred UI separation pattern for WinForms. MVC pattern, I think, is best suited for (state-less) web applications (although its possible to use it in WinForms).

One big benefit of using Passive View (and the reason that I use it) is that it makes your view very "dumb" which makes them much easier to test.

Tip: If you do decide to use Passive View, I would recommend that you take a look at Event Aggregator to decouple the view and the presenter even more, make your application much easier to extend IMHO.

Good Luck!
Robert Blixt, May 18, 2010
Stay Inspired!
Join other developers and designers who have already signed up for our mailing list.
Terms     Privacy     Cookies       Do Not Sell       Licensing      
Made with    in Austin, Texas.  - vsn 44.0.0
© Data & Object Factory, LLC.