我的需求是:改变第一个lookupedit的选择时,第二个lookupedit的数据源随之改变。
我的代码:
private void cbSupplier_EditValueChanged(object sender, EventArgs e)
        {
            int id = Convert.ToInt32(cbSupplier.EditValue);
            try
            {
                cbMaterial.Properties.DataSource = MaterialService.SelectBySupplierId(id);               
            }
            catch (Exception ex)
            {
                log.Debug(ex.Source + "\t" + ex.Message);
            }
        }而且,单步调试的时候我都看见cbMaterial.Properties.DataSource确实变化了,但是界面上完全没有反应,就像是cbMaterial.Properties.DataSource没赋值是空一样。
求助,我该怎么办?