Beispiel #1
0
    private PictureBox CreatePicBox(GridCell GridCell)
    {
        PictureBox picbox = new PictureBox();
        picbox.Click += FormExpand;//connect click eventhandler to event
        picbox.MouseUp += picbox_MouseUp;
        picbox.MouseMove += picbox_MouseMove;
        picbox.Size = new Size(200, 200);
        picbox.BorderStyle = BorderStyle.None;
        picbox.Name = Convert.ToString(GridCell.Number);
        picbox.Location = new Point(GridCell.ReturnLocation().X, GridCell.ReturnLocation().Y);

        return picbox;
    }