If you allow a checkbox to have the Indeterminate state then you should use the GetItemCheckState method to retrieve the state of a check box
for (int i = 0; i < checkedListBox2.Items.Count; i++)
{
CheckState st = checkedListBox2.GetItemCheckState(checkedListBox2.Items.IndexOf(i));
if(st == CheckState.Checked)
....
else if(st == CheckState.Unchecked)
....
else
... // inderminate
}
otherwise is enough to call GetItemChecked that return a true/false value (true also for the indeterminate state)