以下是引用admin22327在2018/12/28 0:13:00的发言:第一 新增入库单不能增加明细
第二 窗口明细里面不能快捷的找到货品信息,主表李可以实现,怎么解决
1、参考2楼的例子,给你的供应商列赋值啊。
2、afterLoad事件
Tables("采购主表.采购明细表").Cols("名称").DropForm = "窗口3"
窗口3事件代码
If e.Selected Then '如果选择了值
Dim tbl As Table = Tables("窗口3_Table1")
If tbl.Current IsNot Nothing Then
e.Form.DropDownBox.Value = tbl.Current("名称")
If e.Form.DropTable IsNot Nothing Then '如果是通过表下拉的
e.Form.DropTable.FinishEditing()
Else '如果是通过窗口下拉的
e.Form.DropDownBox.WriteValue()
End If
End If
End If
If e.Selected Then '如果选择了值
Dim tbl As Table = Tables("窗口3_Table1")
If tbl.Current IsNot Nothing Then
e.Form.DropDownBox.Value = tbl.Current("名称")
e.Form.DropTable.Current("规格") = tbl.Current("规格")
e.Form.DropTable.Current("单位") = tbl.Current("单位")
'Tables("订单").Current("其它列3") = tbl.Current("其它列3")
If e.Form.DropTable IsNot Nothing Then '如果是通过表下拉的
e.Form.DropTable.FinishEditing()
Else '如果是通过窗口下拉的
e.Form.DropDownBox.WriteValue()
End If
End If
End If