C#里CheckListBox的全选

            for (int i = 0; i < chkLSelect.Items.Count; i++)
            {
                if (chkCheck.Checked == true)
                {
                    chkLSelect.SetItemChecked(i, true);
                }
                else
                {
                    chkLSelect.SetItemChecked(i,false);
                }
            }

你可能感兴趣的:(listbox)