Thank you!
如果你想用ESC键关闭窗体,代替你窗体上放置的关闭按钮,
你把窗体的CancelButton属性设为button1
private void button1_Click(object sender, EventArgs e) { this.Close(); }