Windows Forms: Difference between revisions

Content deleted Content added
note that the new .NET 5+ has WinForms, note that WinForms programs can be made in C# or VB
Line 19:
| website = {{URL|https://docs.microsoft.com/en-us/dotnet/framework/winforms/}}
}}
'''Windows Forms''' (WinForms) is a [[free and open-source]] [[graphical user interface|graphical]] (GUI) [[Library (computing)|class library]] included as a part of [[Microsoft]] [[.NET Core|.NET]], [[.NET Framework]] or [[Mono Framework]],<ref>{{cite book|title=Windows Forms Programming in C#|last=Sells|first=Chris|publisher=Addison-Wesley Professional|edition=1st|date=September 6, 2003|page=xxxviiii}}</ref> providing a platform to write rich client applications for desktop, laptop, and tablet PCs.<ref>{{cite web|url=https://msdn.microsoft.com/en-us/library/ff647339.aspx|title=Design and Implementation Guidelines for Web Clients by Microsoft Pattern and Practices|publisher=Microsoft|date=November 2003}}</ref> While it is seen as a replacement for the earlier and more complex [[C++]] based [[Microsoft Foundation Class Library]], it does not offer a comparable paradigm<ref>{{cite book|chapter=Appendix B|title=Moving from MFC, Windows Forms 2.0 Programming|last1=Sells|first1=Chris|last2=Weinhardt|first2=Michael|publisher=Addison-Wesley Professional|edition=2nd|date=May 16, 2006}}</ref> and only acts as a platform for the user interface tier in a [[Multitier architecture|multi-tier]] solution.<ref>{{cite web|title=Introduction to Windows Forms|type=Visual Studio 2003 documentation|publisher=Microsoft 2003|url=https://msdn.microsoft.com/en-us/library/aa983655(v=vs.71).aspx}}</ref>
 
At the [[Microsoft Connect]] event on December 4, 2018, [[Microsoft]] announced releasing Windows Forms as an open source project [https://github.com/dotnet/winforms on GitHub]. It is released under the [[MIT License]]. With this release, Windows Forms has become available for projects targeting the [[.NET Core]] framework. However, the framework is still available only on the Windows platform, and [[Mono Framework|Mono's]] incomplete implementation of Windows Forms remains the only cross-platform implementation.<ref name="OpenSourcingGuiMartin">{{cite web |url=https://www.infoq.com/news/2018/12/msft-open-source-wpf-winforms | title=Microsoft Open Sources WPF, WinForms, and WinUI | last=Martin | first=Jeff | work=InfoQ | date=4 December 2018| archive-date=2018-12-06|access-date=2018-12-06 }}</ref><ref name="OpenSourcingGuiHanselman">{{cite web |url=https://www.hanselman.com/blog/AnnouncingWPFWinFormsAndWinUIAreGoingOpenSource.aspx | title=Announcing WPF, WinForms, and WinUI are going Open Source | last=Hanselman | first=Scott | date=4 December 2018| archive-date=2018-12-06|access-date=2018-12-06 }}</ref>
Line 25:
== Architecture ==
[[File:DotNet3.0.svg|thumb|right|300px|This [[application programming interface|API]] is a part of [[.NET Framework]] 3.0]]
A ''Windows Forms application'' is an [[event-driven programming|event-driven application]] supported by Microsoft's [[.NET Framework]]. Unlike a [[batch processing|batch program]], it spends most of its time simply waiting for the user to do something, such as fill in a [[text box]] or click a [[push-button|button]]. The code for the application can be written in a .NET programming language such as [[C Sharp (programming language)|C#]] or [[Visual Basic .NET|Visual Basic]].
 
Windows Forms provides access to native [[Windows USER|Windows User Interface]] Common Controls by wrapping the existent [[Windows API]] in [[managed code]].<ref>{{cite book|url=http://www.informit.com/articles/article.aspx?p=2048355&seqNum=4|title=C# 4.0 Unleashed|last=De Smet|first=Bart|publisher=Sams Publishing|date=January 4, 2011|chapter=Chapter 5}}</ref> With the help of Windows Forms, the .NET Framework provides a more comprehensive abstraction above the Win32 API than Visual Basic or MFC did.<ref>{{cite book|title=NET Windows Forms in a Nutshell|last1=Griffiths|first1=Ian|last2=Adams|first2=Matthew|publisher=O'Reilly Media|date=March 2003|page=4}}</ref>