using System.Drawing;
using System.Windows.Forms;

public class HelloForms
{
    public static void ShowHelloForm()
    {
        Form form1 = new Form();

        Label label1 = new Label();
        label1.Text = "This is a basic form";
        label1.Anchor = AnchorStyles.Top;
        form1.Controls.Add(label1);

        Button button1 = new Button();
        button1.Text = "Bye!";
        button1.Location = new Point (10, label1.Bottom + 24);
        form1.Controls.Add(button1);

        form1.Text = "Hello Forms";
        form1.CancelButton = button1;
        form1.StartPosition = FormStartPosition.CenterScreen;
        form1.ShowDialog();
    }

    public static void Main(string[] args)
    {
        System.Console.WriteLine("Hello, Forms!");
        ShowHelloForm();
        System.Console.WriteLine("Did you see it?");
    }
}

