/// <summary> /// Remove selected item from white list /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void B_removeFromWhiteList_Click(object sender, EventArgs e) { if (LB_whiteList.SelectedItems.Count > 0) { LB_whiteList.Items.Remove(LB_whiteList.SelectedItem); LB_whiteList.Refresh(); } }
/// <summary> /// Edit selected item from white list /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void B_editSelectedWhiteRecord_Click(object sender, EventArgs e) { if (LB_whiteList.SelectedItems.Count > 0) { TB_addToWhiteList.Text = LB_whiteList.SelectedItem.ToString(); LB_whiteList.Items.Remove(LB_whiteList.SelectedItem); LB_whiteList.Refresh(); } }