All you have to do is change the fixed coordinates in your DrawRectangle to variables, and alter the variables.:
private int rectLeft = 20;
private int rectTop = 30;
protected override void OnPaint(PaintEventArgs paintEvent)
{
Graphics g = paintEvent.Graphics;
Pen pen = new Pen(Color.AliceBlue);
g.DrawRectangle(pen, rectLeft, rectTop, 450, 280);
pen.Dispose();
}
private void button1_Click(object sender, EventArgs e)
{
rectLeft += 20;
rectTop += 10;
Invalidate();
}
(I cut your code down a little to make it clearer)
Note that you are responsible for disposing any pens, brushes, etc. you create! Failure to do so will result in odd seeming problems...