TextBox12,ValueChanged事件
第5行: e.Form.Controls("ComboBox11").ComboList = ""
和后面的这段代码有冲突
Dim cmb As WinForm.ComboBox
cmb = e.Form.Controls("ComboBox11")
cmb.DisplayMember = "谱名" '设置显示列
cmb.ValueMember = "ID" '设置取值列
cmb.DataFilter = "夫ID = '" & zfid & "'"
cmb.DataSort = "排行"
cmb.DataSource = "表B" '列表项目来自于表B
设置了DataSource 后就不能更改ComboList 的值的。
e.Form.Controls("ComboBox11").ComboList = ""
改为
e.Form.Controls("ComboBox11").DataSource = nothing