/// <summary> /// Handles the LinkClicked event of the lnkAddMessenger control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.Windows.Forms.LinkLabelLinkClickedEventArgs"/> instance containing the event data.</param> private void lnkAddMessenger_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { frmDatabaseMessenger frm = new frmDatabaseMessenger(); frm.MessengerAdded += new NewMessengerEventHandler(frm_MessengerAdded); DialogResult result = frm.ShowDialog(); }
/// <summary> /// Edits the db messenger. /// </summary> private void EditMessenger() { object obj = lvwDbMessenger.SelectedObject; if (obj != null) { DbMessenger messenger = obj as DbMessenger; frmDatabaseMessenger frm = new frmDatabaseMessenger(); frm.MessengerUpdated += new UpdateMessengerEventHandler(frm_MessengerUpdated); frm.MessengerName = messenger.Name; DialogResult result = frm.ShowDialog(); } }