private void AddButton_Click_1(object sender, EventArgs e) { UIErrorHelper.CheckedExecNonModal(delegate() { if (this.AddButton.Text == VMwareMMCIDP.UI.Common.Utilities.MMCUIConstants.EDIT) { SetUIToolsEditability(); this.AddButton.Text = VMwareMMCIDP.UI.Common.Utilities.MMCUIConstants.UPDATE; } else if (UIErrorHelper.ShowConfirm(VMwareMMCIDP.UI.Common.Utilities.MMCUIConstants.CONFIRM) == DialogResult.Yes) { DoValidateControls(); FillDTOWithUIControls(); this.Close(); this.DialogResult = DialogResult.OK; } }); }
private void AddButton_Click(object sender, EventArgs e) { if (this.AddButton.Text == "Edit") { this.AddButton.Text = "Update"; SetEditableFields(); } else if (UIErrorHelper.ShowConfirm(VMwareMMCIDP.UI.Common.Utilities.MMCUIConstants.CONFIRM) == DialogResult.Yes) { UIErrorHelper.CheckedExecNonModal(delegate() { DoValidateControls(); UpdateObjectClassDTOWithUIValues(); this.DialogResult = DialogResult.OK; this.Close(); }); } }
public void ViewDiffButtonClicked(object sender, EventArgs e) { UIErrorHelper.CheckedExecNonModal(delegate() { Button button = sender as Button; if (button.Text == VMDirSchemaConstants.DIFF_ATTRIBUTETYPE) { ParseAttrType(); if (AttrDiff == null || AttrDiff.Count == 0) { MMCDlgHelper.ShowInformation("No Diff Found"); } else { var frm = new ViewDiffWindow(this.ServerNode.ServerDTO.Server, this.CurrentNode, MetaDataDiff); frm.ShowDialog(); } } else if (button.Text == VMDirSchemaConstants.DIFF_OBJECTCLASS) { ParseObjectClass(); if (ObjectClassDiff == null || ObjectClassDiff.Count == 0) { MMCDlgHelper.ShowInformation("No Diff Found"); } else { var frm = new ViewDiffWindow(this.ServerNode.ServerDTO.Server, this.CurrentNode, MetaDataDiff); frm.ShowDialog(); } } else { ParseMetaData(); if (MetaDataDiff == null || MetaDataDiff.Count == 0) { MMCDlgHelper.ShowInformation("No Diff Found"); } else { var frm = new ViewDiffWindow(this.ServerNode.ServerDTO.Server, this.CurrentNode, MetaDataDiff); frm.ShowDialog(); } } }); }