private void btnSair_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.Escape) { DesejaSair frm = new DesejaSair(); frm.ShowDialog(); } }
private void sairToolStripMenuItem_Click(object sender, EventArgs e) { DesejaSair frm = new DesejaSair(); frm.ShowDialog(); }