// The protected OnAddFunctoidParameter method raises the event by invoking // the delegates. The sender is always this, the current instance // of the class. protected virtual void OnAddFunctoidParameter(PropertyPairEvent e) { if (e != null) { // Invokes the delegates. _AddFunctoidParameterEvent(this, e); } }
/// <summary> /// The protected OnRaiseProperty method raises the event by invoking /// the delegates. The sender is always this, the current instance /// of the class. /// </summary> /// <param name="e"></param> protected virtual void OnAddWizardResult(PropertyPairEvent e) { if (e != null) { // Invokes the delegates. _AddWizardResultEvent(this, e); } }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void AddFunctoidParameters(object sender, PropertyPairEvent e) { try { AddProperty(FunctoidParameters, e); } catch (Exception err) { MessageBox.Show(this, err.Message); } }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void AddWizardResult(object sender, PropertyPairEvent e) { try { // Replace the value if it already exists if (_wizardResults[e.Name] != null) { _wizardResults.Remove(e.Name); } _wizardResults.Add(e.Name, e.Value); } catch (Exception err) { MessageBox.Show(this, err.Message); } }
/// <summary> /// /// </summary> /// <param name="nvc"></param> /// <param name="e"></param> private void AddProperty(NameValueCollection nvc, PropertyPairEvent e) { if (e.Remove) { if (nvc[e.Name] != null) { nvc.Remove(e.Name); } return; } // Replace the value if it already exists if (nvc[e.Name] != null) { nvc.Remove(e.Name); } nvc.Add(e.Name, (string)e.Value); }
/// <summary> /// /// </summary> /// <param name="nvc"></param> /// <param name="e"></param> private void AddProperty(Hashtable nvc, PropertyPairEvent e) { if (e.Remove) { if (nvc[e.Name] != null) { nvc.Remove(e.Name); } return; } // Replace the value if it already exists if (nvc[e.Name] != null) { nvc.Remove(e.Name); } nvc.Add(e.Name, e.Value); }
protected void AddWizardResult(string strName, object Value) { PropertyPairEvent PropertyPair = new PropertyPairEvent(strName, Value); OnAddWizardResult(PropertyPair); }
protected void RemoveFunctoidParameter(string strName) { PropertyPairEvent PropertyPair = new PropertyPairEvent(strName, null, true); OnAddFunctoidParameter(PropertyPair); }
protected void AddFunctoidParameter(string strName, string strValue) { PropertyPairEvent PropertyPair = new PropertyPairEvent(strName, strValue); OnAddFunctoidParameter(PropertyPair); }