C#: Introduction to Forms
|Tell a friend about this site (copy and paste the following HTML page into a file (e.g., using Notepad).)|
<title>C#: Table of Contents </title>
The purpose of this tutorial is to introduce you to the basics of C# ("C sharp") forms. Even if you've never programmed in a language similar to C/C++ or Java before, this tutorial should be very easy to follow and understand. It assumes that you have some basic exposure to programming (some object-oriented experience would be helpful, but is not necessary) and you have some kind of C# compiler (if you would like to run the examples). First, you should know that C# is a language designed by Microsoft. It is intended to combine the most significant parts of C/C++ along with the productivity of a 4GL, such as Visual Basic.
Windows Forms is the .NET replacement for MFC. Unlike the MFC library, which was a thin wrapper on the Win32 API, Windows Forms is a totally object-oriented, hierarchical based for Windows development under .NET . Similar to Java's Abstract Window Toolkit (AWT), Windows Forms was an early and easy way to provide graphical user interface components to the .NET Framework. Windows Forms (WinForms) is the name given to the graphical application programming interface (API) included as a part of Microsoft .NET Framework,You should have read and mastered:
Instructions on how to obtain one will be described in the next section, if you do not have a C# compiler.
If you don't have a c# compiler, you can download a free copy at Microsoft's Visual Studio Downloads Page. This download may take approximately 24 hours using a 56 kbps dial-up. You may be able to download a copy in 5-10 minutes, if you have access to a T1 line at a public college or a public library, assuming a line is available. You may be able to download a copy in 15-20 minutes, if you have access to a broadband internet provider. You can follow the steps below:
The foundation of most solutions that involve Windows Forms is the Windows Forms Application project. Creating a project is easy within the integrated development environment (IDE).
Start Visual Studio 2012.
On the File menu, point to New, and then select Project.
The New Project dialog box appears.
In the Installed Templates pane, expand Visual C#, and then select Window Forms Application.
Above the middle pane, select the target framework from the drop-down list.
In the middle pane, select the Windows Forms Application template.
The Windows Forms Application template in the .NET Framework 4 targets the Client Profile by default.
In the Name text box, specify a name for the project.
In the Location text box, specify a folder to save the project.
The Windows Forms Designer opens and displays Form1 of the project.
© 2002 - 2013 All Rights Reserved Total Application Works