以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  选择框发生变化后  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=42842)

--  作者:Liangcai
--  发布时间:2013/11/23 21:39:00
--  选择框发生变化后

当窗口1物品编号(ComboBox)框选择"2013001"后,返还人(Label)显示固定资产出库表中"张三"。请指教代码

 下载信息  [文件大小:   下载次数: ]
图片点击可在新窗口打开查看点击浏览该文件:管理项目.zip

[此贴子已经被作者于2013-11-23 21:41:47编辑过]

--  作者:有点甜
--  发布时间:2013/11/23 21:47:00
--  
 编写combobox的textchanged事件

Dim dt As DataTable = DataTables("固定资产出库")
Dim fdr As DataRow = dt.Find("物品编号 = \'" & e.Sender.Text & "\'")
If fdr IsNot Nothing Then
    e.Form.Controls("返还人").text = fdr("领物人")
Else
    e.Form.Controls("返还人").text = ""
End If

--  作者:Liangcai
--  发布时间:2013/11/23 21:59:00
--  

谢谢!