Input for WinForms | ComponentOne
Input Controls / PictureBox
In This Topic
    PictureBox
    In This Topic

    The PictureBox control represents a rectangular region used to display graphics such as images from a bitmap, metafile, icon, JPEG, GIF, or PNG file. You can set the Image property to set the image in the PictureBox control. The control also provides SizeMode property which lets you set how the image should be positioned inside the picture box. The property lets you display the image as stretched, normal, zoomed or autosized. 

    PictureBox control

    Add PictureBox Control
    Copy Code
    pic = new C1PictureBox();
    Controls.Add(pic);
    pic.Location = new Point(10, 220);
    pic.Image = Image.FromFile("c:\\Users\\Dell\\Desktop\\AR.png");
    pic.Size = new Size(120, 100);
    pic.SizeMode = PictureBoxSizeMode.StretchImage;