private void OnDeleteProjectClick(object o, EventArgs e) { try { if (MessageBox.Show("Are you sure?", "Confirm", MessageBoxButtons.OKCancel, MessageBoxIcon.Asterisk, MessageBoxDefaultButton.Button2) == DialogResult.OK) { ProjectNode pn = this.SelectedNode as ProjectNode; if (pn != null && pn.Project != null) { ConfigCtrl.DeleteProject(pn.Project); VsVersionNode vvn = pn.Parent as VsVersionNode; RefreshVsVersionNode(vvn); } } } catch (Exception ex) { MessageBox.Show(ex.Message, CGConstants.MSG_SYSTEMERROR, MessageBoxButtons.OK, MessageBoxIcon.Error); } }