First Window Application : Introduction « GUI Windows Forms « C# / CSharp Tutorial






First Window Application
using System;
    using System.Drawing;
    using System.Collections;
    using System.ComponentModel;
    using System.Windows.Forms;
    using System.Data;
    
    public class MyFirstWindow : System.Windows.Forms.Form
    {
        public MyFirstWindow()
        {
            InitializeComponent();
        }
        
        
        private void InitializeComponent()
        {
            this.Size = new System.Drawing.Size(300,300);
            this.Text = "MyFirstWindow";
        }
        
        public static void Main(string[] args) 
        {
            Application.Run(new MyFirstWindow());
        }
    }








23.1.Introduction
23.1.1.Empty FormEmpty Form
23.1.2.First Window ApplicationFirst Window Application
23.1.3.A form-based Windows Skeleton
23.1.4.Exit application
23.1.5.Button click handlerButton click handler
23.1.6.Use Application.Run to load window application
23.1.7.Subclass Form to create a window
23.1.8.Essential elements of a Windows Forms application.