private void panel1_Paint(object sender, PaintEventArgs e) { panel1.Location = new Point(10, 10); //中间的数据填写你想要的 }
1. 一般赋值 panel3.Location = new Point(X,Y);2.MouseClick事件 panel3.Location = new Point(e.X ,e.Y);