How to get value of checked item from CheckedListBox?

Cast it back to its original type, which will be a DataRowView if you’re binding a table, and you can then get the Id and Text from the appropriate columns: foreach(object itemChecked in checkedListBox1.CheckedItems) { DataRowView castedItem = itemChecked as DataRowView; string comapnyName = castedItem[“CompanyName”]; int? id = castedItem[“ID”]; }

Which CheckedListBox event triggers after a item is checked?

You can use the ItemCheck event, if you also check the new state of the item which is being clicked. This is available in the event args, as e.NewValue. If NewValue is checked, include the current item along with the collection proper in your logic: private void checkedListBox1_ItemCheck(object sender, ItemCheckEventArgs e) { List<string> checkedItems = … Read more