When I look at the project properties in Visual Studio for my particular project, there is a field called Output Type which says Windows Application. Does that automatically tell me that it's a WinForms application? I'm trying to find a way to determine right away if the project is a Winforms application. Yes, I can look at the files and determine that by looking at the forms. But I'm wondering if there is a more obvious way to determine that by simply looking at a project's properties.
The other reason I'm asking is because when I look at the project properties of a WPF application, the Output Type is also Windows Application. The way to determine that it's a WPF app is by looking for XAML files. So is there a simpler technique to determine what type of app it is by looking at project properties?
Windows Presentation Foundation (WPF) in Visual Studio provides developers with a unified programming model for building line-of-business desktop applications on Windows.
Windows Forms (WinForms) is a free and open-source graphical (GUI) class library included as a part of Microsoft . NET, . NET Framework or Mono Framework, providing a platform to write client applications for desktop, laptop, and tablet PCs.
WinForms won't be deprecated until Win32 is ... which could be quite sometime! WPF on the other hand has few direct dependencies on Win32 so could potentially form the basis of a "fresh start" UI layer on a future version of windows.
You can tell by what assemblies the project references. Does it reference assemblies beneath System.Windows.Forms
? If so, it's WinForms. If it only references namespaces beneath System.Windows
other than System.Windows.Forms
, then it's WPF.
Check the type of your main form -- is it a System.Windows.Forms.Form
? If so, it's a WinForms project. If it's a System.Windows.Window
, then it's WPF.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With