string strq = "select Stru_chName,Stru_enName from T_StuRowName;"; SqlCommand command = new SqlCommand(strq, con); SqlDataReader reader = command.ExecuteReader(); BindingSource bs = new BindingSource(); bs.DataSource = reader; checkedListBox1.DataSource = bs; checkedListBox1.ValueMember = "Stru_enName"; checkedListBox1.DisplayMember = "Stru_chName";
checkedListBox的数据绑定,布布扣,bubuko.com
时间: 2024-10-22 08:42:42