PictureBox visible and invisible

using System;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
public class ListText : Form {

private Button choose = new Button();
private ListBox animalList = new ListBox( );
private ListBox things = new ListBox( );
private TextBox text = new TextBox( );
private PictureBox picture = new PictureBox();
private PictureBox photo = new PictureBox();
private CheckBox show = new CheckBox();
private CheckBox author = new CheckBox();

private Bitmap moon = new Bitmap(“winter.jpg”);

public ListText( ) {
Text = “List Text”;
choose.Text = “Choose”;
show.Text = “Show a bitmap”;
author.Text = “Show another bitmap”;

Size = new Size(400, 300);
choose.Size = new Size(100,20);
text.Size = new Size(150,50);
photo.Size = new Size(100,100);

choose.Location = new Point(20,30);
animalList.Location = new Point(30 + choose.Width, 30);
things.Location = new Point(40 + choose.Width + animalList.Width, 30);
text.Location = new Point(20, 150);
photo.Location = new Point(40 + text.Width, 150);
picture.Location = new Point(60 + text.Width + photo.Width, 150);
show.Location = new Point(20,70);
author.Location = new Point(20,110);

animalList.SelectionMode = SelectionMode.MultiSimple;
things.SelectionMode = SelectionMode.One;
text.Multiline = true;
picture.Image = (Image)moon;
picture.Visible = false;
photo.Image = Image.FromFile(“winter.jpg”);
photo.Visible = false;
BackColor = Color.White;
choose.BackColor = Color.Pink;

animalList.Items.Add(“A”);
animalList.Items.Add(“B”);
animalList.Items.Add(“C”);
animalList.Items.Add(“D”);
animalList.Items.Add(“E”);
things.Items.Add(“1”);
things.Items.Add(“2”);
things.Items.Add(“3”);
things.Items.Add(“4”);

Controls.Add(animalList);
Controls.Add(things);
Controls.Add(choose);
Controls.Add(text);
Controls.Add(picture);
Controls.Add(show);
Controls.Add(author);
Controls.Add(photo);

choose.Click += new EventHandler(Choose_Click);
things.SelectedIndexChanged += new EventHandler(Things_Changed);
show.CheckedChanged += new EventHandler(Picture_Changed);
author.CheckedChanged += new EventHandler(Photo_Changed);
}

protected void Choose_Click(object sender, EventArgs e) {
for(int i = 0; i < animalList.SelectedItems.Count; i++){ Console.WriteLine(animalList.SelectedItems[i].ToString()); } } protected void Things_Changed(object sender, EventArgs e) { text.Text = "You selected " + things.SelectedItem; } protected void Picture_Changed(Object sender, EventArgs e) { if (show.Checked) picture.Visible = true; else picture.Visible = false; Invalidate(); } protected void Photo_Changed(Object sender, EventArgs e) { if (author.Checked) photo.Visible = true; else photo.Visible = false; Invalidate(); } static void Main() { Application.Run(new ListText()); } } [/csharp]

PictureBox Scroll Text

   
 

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

public class Form1 : Form {
    Font textFont = new Font("Times New Roman", 24);

    public Form1() {
        this.panel1 = new System.Windows.Forms.Panel();
        this.pictureBox1 = new System.Windows.Forms.PictureBox();
        this.panel1.SuspendLayout();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
        this.SuspendLayout();
        this.panel1.AutoScroll = true;
        this.panel1.AutoScrollMinSize = new System.Drawing.Size(600, 400);
        this.panel1.Controls.Add(this.pictureBox1);
        this.panel1.Location = new System.Drawing.Point(13, 13);
        this.panel1.Size = new System.Drawing.Size(267, 243);
        this.pictureBox1.BackColor = System.Drawing.SystemColors.Window;
        this.pictureBox1.Dock = System.Windows.Forms.DockStyle.Fill;
        this.pictureBox1.Location = new System.Drawing.Point(0, 0);
        this.pictureBox1.Size = new System.Drawing.Size(600, 400);
        this.pictureBox1.TabStop = false;
        this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
        this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
        this.ClientSize = new System.Drawing.Size(292, 268);
        this.Controls.Add(this.panel1);
        this.Load += new System.EventHandler(this.Form1_Load);
        this.panel1.ResumeLayout(false);
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
        this.ResumeLayout(false);
    }
    private void Form1_Load(object sender, EventArgs e) {
        Bitmap b = new Bitmap(600, 600);
        Graphics g = Graphics.FromImage(b);
        g.FillRectangle(Brushes.White, new Rectangle(0, 0, b.Width, b.Height));
        g.DrawString("Hello, World", textFont, Brushes.Black, 40, 40);
        g.DrawString("Hello, World", textFont, Brushes.Red, 40, 240);
        g.DrawString("Hello, World", textFont, Brushes.Blue, 350, 40);
        g.DrawString("Hello, World", textFont, Brushes.Green, 350, 240);
        pictureBox1.BackgroundImage = b;
        pictureBox1.Size = b.Size;
    }
    private System.Windows.Forms.Panel panel1;
    private System.Windows.Forms.PictureBox pictureBox1;
    [STAThread]
    static void Main() {
        Application.EnableVisualStyles();
        Application.Run(new Form1());
    }
}

    


PictureBox Click event


   


   using System;
   using System.Drawing;
   using System.Collections;
   using System.ComponentModel;
   using System.Windows.Forms;
   using System.Data;
   using System.IO;

   public class PictureBoxTest : System.Windows.Forms.Form
   {
      private System.Windows.Forms.PictureBox imagePictureBox;
      private System.Windows.Forms.Label promptLabel;

      public PictureBoxTest()
      {
         InitializeComponent();
      }

      private void InitializeComponent()
      {
         this.promptLabel = new System.Windows.Forms.Label();
         this.imagePictureBox = new System.Windows.Forms.PictureBox();
         this.SuspendLayout();

         this.promptLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
         this.promptLabel.Location = new System.Drawing.Point(22, 8);
         this.promptLabel.Name = "promptLabel";
         this.promptLabel.Size = new System.Drawing.Size(124, 56);
         this.promptLabel.TabIndex = 0;
         this.promptLabel.Text = "Click On PictureBox to View Images";
         this.promptLabel.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;

         this.imagePictureBox.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
         this.imagePictureBox.Location = new System.Drawing.Point(34, 72);
         this.imagePictureBox.Name = "imagePictureBox";
         this.imagePictureBox.Size = new System.Drawing.Size(100, 100);
         this.imagePictureBox.TabIndex = 1;
         this.imagePictureBox.TabStop = false;

         this.imagePictureBox.Click += new System.EventHandler(this.imagePictureBox_Click );

         this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
         this.ClientSize = new System.Drawing.Size(168, 189);
         this.Controls.AddRange(new System.Windows.Forms.Control[] {this.imagePictureBox,
                                                                      this.promptLabel});
         this.Text = "PictureBoxTest";
         this.ResumeLayout(false);

      }
      [STAThread]
      static void Main() 
      {
         Application.Run( new PictureBoxTest() );
      }

      private void imagePictureBox_Click(object sender, System.EventArgs e )
      {
         imagePictureBox.Image = Image.FromFile(Directory.GetCurrentDirectory() + "winter.jpg" );
      }

   }



           
          


Set password mask char


   


    using System;
    using System.Drawing;
    using System.Collections;
    using System.ComponentModel;
    using System.Windows.Forms;
    using System.Data;

  public class TextForm : System.Windows.Forms.Form
    {
    private System.Windows.Forms.Button btnPasswordDecoderRing;
    private System.Windows.Forms.Label label3;
    private System.Windows.Forms.TextBox passwordBox;
    private System.Windows.Forms.Label label2;
    private System.Windows.Forms.TextBox capsOnlyBox;
    private System.Windows.Forms.Button btnGetMultiLineText;
    private System.Windows.Forms.Label label1;
    private System.Windows.Forms.TextBox multiLineBox;

        public TextForm()
        {
            InitializeComponent();
        }

    private void InitializeComponent()
    {
      this.capsOnlyBox = new System.Windows.Forms.TextBox();
      this.multiLineBox = new System.Windows.Forms.TextBox();
      this.label1 = new System.Windows.Forms.Label();
      this.label2 = new System.Windows.Forms.Label();
      this.passwordBox = new System.Windows.Forms.TextBox();
      this.btnGetMultiLineText = new System.Windows.Forms.Button();
      this.btnPasswordDecoderRing = new System.Windows.Forms.Button();
      this.label3 = new System.Windows.Forms.Label();
      this.capsOnlyBox.CharacterCasing = System.Windows.Forms.CharacterCasing.Upper;
      this.capsOnlyBox.Location = new System.Drawing.Point(14, 176);
      this.capsOnlyBox.Size = new System.Drawing.Size(120, 20);
      this.capsOnlyBox.TabIndex = 3;
      this.multiLineBox.AcceptsReturn = true;
      this.multiLineBox.AcceptsTab = true;
      this.multiLineBox.Location = new System.Drawing.Point(152, 8);
      this.multiLineBox.Multiline = true;
      this.multiLineBox.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
      this.multiLineBox.Size = new System.Drawing.Size(240, 104);
      this.multiLineBox.TabIndex = 0;
      this.multiLineBox.Text = "Get text from multiline textbox";
      this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F);
      this.label1.Location = new System.Drawing.Point(8, 8);
      this.label1.Size = new System.Drawing.Size(136, 56);
      this.label1.TabIndex = 1;
      this.label1.Text = "this is a multiline text box";
      this.label2.Font = new System.Drawing.Font("Comic Sans MS", 12F);
      this.label2.Location = new System.Drawing.Point(14, 144);
      this.label2.Size = new System.Drawing.Size(106, 24);
      this.label2.TabIndex = 4;
      this.label2.Text = "Caps only!!";
      this.passwordBox.Location = new System.Drawing.Point(160, 176);
      this.passwordBox.PasswordChar = &#039;$&#039;;
      this.passwordBox.Size = new System.Drawing.Size(232, 20);
      this.passwordBox.TabIndex = 5;
      this.passwordBox.Text = "password";
      this.btnGetMultiLineText.Location = new System.Drawing.Point(13, 72);
      this.btnGetMultiLineText.Size = new System.Drawing.Size(120, 32);
      this.btnGetMultiLineText.TabIndex = 2;
      this.btnGetMultiLineText.Text = "Get Text";
      this.btnGetMultiLineText.Click += new System.EventHandler(this.btnGetMultiLineText_Click);
      this.btnPasswordDecoderRing.Location = new System.Drawing.Point(280, 144);
      this.btnPasswordDecoderRing.Size = new System.Drawing.Size(112, 24);
      this.btnPasswordDecoderRing.TabIndex = 7;
      this.btnPasswordDecoderRing.Text = "Decode Password";
      this.btnPasswordDecoderRing.Click += new System.EventHandler(this.btnPasswordDecoderRing_Click);
      this.label3.Font = new System.Drawing.Font("Comic Sans MS", 12F);
      this.label3.Location = new System.Drawing.Point(152, 144);
      this.label3.Size = new System.Drawing.Size(120, 24);
      this.label3.TabIndex = 6;
      this.label3.Text = "Password Box";
      this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
      this.ClientSize = new System.Drawing.Size(408, 221);
      this.Controls.AddRange(new System.Windows.Forms.Control[] {this.btnPasswordDecoderRing,
                                      this.label3,
                                      this.passwordBox,
                                      this.label2,
                                      this.capsOnlyBox,
                                      this.btnGetMultiLineText,
                                      this.label1,
                                      this.multiLineBox});
      this.Text = "TextBox Types";

    }

    protected void btnPasswordDecoderRing_Click (object sender, System.EventArgs e)
    {
      MessageBox.Show(passwordBox.Text, "Your password is:");
    }

    protected void btnGetMultiLineText_Click (object sender, System.EventArgs e)
    {
      MessageBox.Show(multiLineBox.Text, "Here is your text");
    }

        public static void Main(string[] args) 
        {
            Application.Run(new TextForm());
        }
    }


           
          


Get input from password textbox


   


    using System;
    using System.Drawing;
    using System.Collections;
    using System.ComponentModel;
    using System.Windows.Forms;
    using System.Data;

  public class TextForm : System.Windows.Forms.Form
    {
    private System.Windows.Forms.Button btnPasswordDecoderRing;
    private System.Windows.Forms.Label label3;
    private System.Windows.Forms.TextBox passwordBox;
    private System.Windows.Forms.Label label2;
    private System.Windows.Forms.TextBox capsOnlyBox;
    private System.Windows.Forms.Button btnGetMultiLineText;
    private System.Windows.Forms.Label label1;
    private System.Windows.Forms.TextBox multiLineBox;

        public TextForm()
        {
            InitializeComponent();
        }

    private void InitializeComponent()
    {
      this.capsOnlyBox = new System.Windows.Forms.TextBox();
      this.multiLineBox = new System.Windows.Forms.TextBox();
      this.label1 = new System.Windows.Forms.Label();
      this.label2 = new System.Windows.Forms.Label();
      this.passwordBox = new System.Windows.Forms.TextBox();
      this.btnGetMultiLineText = new System.Windows.Forms.Button();
      this.btnPasswordDecoderRing = new System.Windows.Forms.Button();
      this.label3 = new System.Windows.Forms.Label();
      this.capsOnlyBox.CharacterCasing = System.Windows.Forms.CharacterCasing.Upper;
      this.capsOnlyBox.Location = new System.Drawing.Point(14, 176);
      this.capsOnlyBox.Size = new System.Drawing.Size(120, 20);
      this.capsOnlyBox.TabIndex = 3;
      this.multiLineBox.AcceptsReturn = true;
      this.multiLineBox.AcceptsTab = true;
      this.multiLineBox.Location = new System.Drawing.Point(152, 8);
      this.multiLineBox.Multiline = true;
      this.multiLineBox.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
      this.multiLineBox.Size = new System.Drawing.Size(240, 104);
      this.multiLineBox.TabIndex = 0;
      this.multiLineBox.Text = "Get text from multiline textbox";
      this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F);
      this.label1.Location = new System.Drawing.Point(8, 8);
      this.label1.Size = new System.Drawing.Size(136, 56);
      this.label1.TabIndex = 1;
      this.label1.Text = "this is a multiline text box";
      this.label2.Font = new System.Drawing.Font("Comic Sans MS", 12F);
      this.label2.Location = new System.Drawing.Point(14, 144);
      this.label2.Size = new System.Drawing.Size(106, 24);
      this.label2.TabIndex = 4;
      this.label2.Text = "Caps only!!";
      this.passwordBox.Location = new System.Drawing.Point(160, 176);
      this.passwordBox.PasswordChar = &#039;$&#039;;
      this.passwordBox.Size = new System.Drawing.Size(232, 20);
      this.passwordBox.TabIndex = 5;
      this.passwordBox.Text = "password";
      this.btnGetMultiLineText.Location = new System.Drawing.Point(13, 72);
      this.btnGetMultiLineText.Size = new System.Drawing.Size(120, 32);
      this.btnGetMultiLineText.TabIndex = 2;
      this.btnGetMultiLineText.Text = "Get Text";
      this.btnGetMultiLineText.Click += new System.EventHandler(this.btnGetMultiLineText_Click);
      this.btnPasswordDecoderRing.Location = new System.Drawing.Point(280, 144);
      this.btnPasswordDecoderRing.Size = new System.Drawing.Size(112, 24);
      this.btnPasswordDecoderRing.TabIndex = 7;
      this.btnPasswordDecoderRing.Text = "Decode Password";
      this.btnPasswordDecoderRing.Click += new System.EventHandler(this.btnPasswordDecoderRing_Click);
      this.label3.Font = new System.Drawing.Font("Comic Sans MS", 12F);
      this.label3.Location = new System.Drawing.Point(152, 144);
      this.label3.Size = new System.Drawing.Size(120, 24);
      this.label3.TabIndex = 6;
      this.label3.Text = "Password Box";
      this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
      this.ClientSize = new System.Drawing.Size(408, 221);
      this.Controls.AddRange(new System.Windows.Forms.Control[] {this.btnPasswordDecoderRing,
                                      this.label3,
                                      this.passwordBox,
                                      this.label2,
                                      this.capsOnlyBox,
                                      this.btnGetMultiLineText,
                                      this.label1,
                                      this.multiLineBox});
      this.Text = "TextBox Types";

    }

    protected void btnPasswordDecoderRing_Click (object sender, System.EventArgs e)
    {
      MessageBox.Show(passwordBox.Text, "Your password is:");
    }

    protected void btnGetMultiLineText_Click (object sender, System.EventArgs e)
    {
      MessageBox.Show(multiLineBox.Text, "Here is your text");
    }

        public static void Main(string[] args) 
        {
            Application.Run(new TextForm());
        }
    }


           
          


Scrolling Picture

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

public class Form1 : Form {
public Form1() {
this.panel1 = new System.Windows.Forms.Panel();
this.SuspendLayout();
this.panel1.AutoScroll = true;
this.panel1.BackgroundImage = new Bitmap(“yourfile.bmp”);
this.panel1.Location = new System.Drawing.Point(13, 13);
this.panel1.Size = new System.Drawing.Size(267, 243);
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(292, 268);
this.Controls.Add(this.panel1);
this.Load += new System.EventHandler(this.Form1_Load);
this.ResumeLayout(false); this.panel1.AutoScrollMinSize = this.panel1.BackgroundImage.Size;
}

private void Form1_Load(object sender, EventArgs e) {
int midX = this.panel1.AutoScrollMinSize.Width / 2;
int midY = this.panel1.AutoScrollMinSize.Height / 2;
int halfSizeX = this.panel1.Size.Width / 2;
int halfSizeY = this.panel1.Size.Height / 2;
int startPosX = midX – halfSizeX;
if (startPosX < 0) startPosX = 0; int startPosY = midY - halfSizeY; if (startPosY < 0) startPosY = 0; this.panel1.AutoScrollPosition = new Point(startPosX, startPosY); } private System.Windows.Forms.Panel panel1; [STAThread] static void Main() { Application.EnableVisualStyles(); Application.Run(new Form1()); } } [/csharp]

Scrollable Panel


   

/*
User Interfaces in C#: Windows Forms and Custom Controls
by Matthew MacDonald

Publisher: Apress
ISBN: 1590590457
*/

using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;

namespace UnsualScrolling
{
    /// <summary>
    /// Summary description for ScrollablePanel.
    /// </summary>
    public class ScrollablePanel : System.Windows.Forms.Form
    {
        internal System.Windows.Forms.Panel Panel1;
        internal System.Windows.Forms.Button Button6;
        internal System.Windows.Forms.Button Button5;
        internal System.Windows.Forms.Button Button4;
        internal System.Windows.Forms.Button Button3;
        internal System.Windows.Forms.Button Button2;
        internal System.Windows.Forms.Button Button1;
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.Container components = null;

        public ScrollablePanel()
        {
            //
            // Required for Windows Form Designer support
            //
            InitializeComponent();

            //
            // TODO: Add any constructor code after InitializeComponent call
            //
        }

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        protected override void Dispose( bool disposing )
        {
            if( disposing )
            {
                if(components != null)
                {
                    components.Dispose();
                }
            }
            base.Dispose( disposing );
        }

        #region Windows Form Designer generated code
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.Panel1 = new System.Windows.Forms.Panel();
            this.Button6 = new System.Windows.Forms.Button();
            this.Button5 = new System.Windows.Forms.Button();
            this.Button4 = new System.Windows.Forms.Button();
            this.Button3 = new System.Windows.Forms.Button();
            this.Button2 = new System.Windows.Forms.Button();
            this.Button1 = new System.Windows.Forms.Button();
            this.Panel1.SuspendLayout();
            this.SuspendLayout();
            // 
            // Panel1
            // 
            this.Panel1.Anchor = (((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
                | System.Windows.Forms.AnchorStyles.Left) 
                | System.Windows.Forms.AnchorStyles.Right);
            this.Panel1.AutoScroll = true;
            this.Panel1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.Panel1.Controls.AddRange(new System.Windows.Forms.Control[] {
                                                                                 this.Button6,
                                                                                 this.Button5,
                                                                                 this.Button4,
                                                                                 this.Button3,
                                                                                 this.Button2,
                                                                                 this.Button1});
            this.Panel1.Location = new System.Drawing.Point(4, 8);
            this.Panel1.Name = "Panel1";
            this.Panel1.Size = new System.Drawing.Size(348, 172);
            this.Panel1.TabIndex = 2;
            // 
            // Button6
            // 
            this.Button6.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.Button6.Location = new System.Drawing.Point(16, 180);
            this.Button6.Name = "Button6";
            this.Button6.Size = new System.Drawing.Size(168, 24);
            this.Button6.TabIndex = 5;
            this.Button6.Text = "Button6";
            // 
            // Button5
            // 
            this.Button5.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.Button5.Location = new System.Drawing.Point(16, 148);
            this.Button5.Name = "Button5";
            this.Button5.Size = new System.Drawing.Size(168, 24);
            this.Button5.TabIndex = 4;
            this.Button5.Text = "Button5";
            // 
            // Button4
            // 
            this.Button4.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.Button4.Location = new System.Drawing.Point(16, 116);
            this.Button4.Name = "Button4";
            this.Button4.Size = new System.Drawing.Size(168, 24);
            this.Button4.TabIndex = 3;
            this.Button4.Text = "Button4";
            // 
            // Button3
            // 
            this.Button3.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.Button3.Location = new System.Drawing.Point(16, 84);
            this.Button3.Name = "Button3";
            this.Button3.Size = new System.Drawing.Size(168, 24);
            this.Button3.TabIndex = 2;
            this.Button3.Text = "Button3";
            // 
            // Button2
            // 
            this.Button2.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.Button2.Location = new System.Drawing.Point(16, 52);
            this.Button2.Name = "Button2";
            this.Button2.Size = new System.Drawing.Size(168, 24);
            this.Button2.TabIndex = 1;
            this.Button2.Text = "Button2";
            // 
            // Button1
            // 
            this.Button1.FlatStyle = System.Windows.Forms.FlatStyle.System;
            this.Button1.Location = new System.Drawing.Point(16, 20);
            this.Button1.Name = "Button1";
            this.Button1.Size = new System.Drawing.Size(168, 24);
            this.Button1.TabIndex = 0;
            this.Button1.Text = "Button1";
            // 
            // ScrollablePanel
            // 
            this.AutoScaleBaseSize = new System.Drawing.Size(5, 14);
            this.ClientSize = new System.Drawing.Size(360, 194);
            this.Controls.AddRange(new System.Windows.Forms.Control[] {
                                                                          this.Panel1});
            this.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(0)));
            this.Name = "ScrollablePanel";
            this.Text = "Scrollable Panel";
            this.Panel1.ResumeLayout(false);
            this.ResumeLayout(false);

        }
        #endregion

        static void Main() 
        {
            Application.Run(new ScrollablePanel());
        }
    }
}