winfrom 窗体关闭友好提示
private void from_close(object sender, FormClosedEventArgs e)
{
//接收返回值 DialoResult是用来接收的
DialogResult a = MessageBox.Show("确定关闭窗体","警告",MessageBoxButtons.YesNoCancel,MessageBoxIcon.Error);
if (a == DialogResult.Yes)
{
e.Cancel = false;
}
else {
}
}
我的e点不出来Cancel是为什么