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

namespace EX2
{
    public partial class frmChangePicSize : Form
    {
        public frmChangePicSize()
        {
            InitializeComponent();
        }

        private void frmChangePicSize_KeyDown(object sender, KeyEventArgs e)
        {
            if (e.KeyCode == Keys.Left)
                pictureBox1.Width = pictureBox1.Width - 10;
            else if (e.KeyCode==Keys.Right)
                pictureBox1.Width = pictureBox1.Width + 10;
            else if (e.KeyCode == Keys.Up)
                pictureBox1.Height = pictureBox1.Height + 10;
            else if (e.KeyCode == Keys.Down)
                pictureBox1.Height = pictureBox1.Height - 10;
        }
    }
}
