I know that there is a checkedListBox event called ItemChecked and I think there's a CheckChanged event for individual checkboxes, but is there an ItemUnchecked or CheckChanged event counterpart for a checkedListBox? If so, how would I subscribe to it and implement/use it?
When I use the "NewValue" method recommended, it just spits back an error and states: "'EventArgs' does not contain a definition for 'NewValue' and no accessible extension method 'NewValue' accepting a first argument of type 'EventArgs' could be found (are you missing a using directive or an assembly reference?)". Does anyone have any advice?
My goal is to create a piece of code as a counterpart to the ItemChecked event so that if the user unchecks a box, it will undo the effect the checking event had.
Example of what I want to be able to do:
private void checkedListBoxBasics_ItemUnCheck(object sender, EventArgs e)
{
//The variable "index" was instantiated previously in the code.
//get index of checked box and set variable index to that
index = checkedListBoxBasics.SelectedIndex;
if (index == 0)
{
updateResourcesUncheck("checkedListBoxBasics", 100000, 0, 0, 0, 0, 0, 0, 0);
}
}