System.Windows.Forms.DialogResult result = MessageBox.Show("Are you sure", "Close?", MessageBoxButtons.OkCancel,MessageBoxIcon.Question); if (result == System.Windows.Forms.DialogResult.Ok) { // Do your thing here }
Comment