日期:2014-05-19  浏览次数:20841 次

怎样获取checkedListBox 中选中的项的文本?
怎样获得呢?我想获取checkedListBox中所选中(打勾)的文本,怎样获得?如果选择了多项,应该怎样一项一项的取出呢?

------解决方案--------------------
string output = string.Empty;
for (int i = 0; i < checkedListBox1.CheckedIndices.Count; i++)
{
output += checkedListBox1.Items[
checkedListBox1.CheckedIndices[i]].ToString() + "\r\n ";
}
MessageBox.Show(output);