我在组合框控件中选择了一个项目并且associatename的值显示为null时出现错误。
private void cmbAssociateName_SelectionChangeCommitted(object sender, EventArgs e)
{
ComboBox c = (ComboBox)sender;
object associatename = c.SelectedText;
DataTable dtAssociateID = objMainModuleBO.GetAssociateIDByName(associatename);
Utilities.BindDataSource(cmbAssociateID, dtAssociateID, MSTAssociateMasterTO.ASSOCIATEID, null);
}