我有一个查询,其中包含以下字段
OrderID
[Forms]![FMain_Orders]![OrderID]
Sum Of the Board Feet
Sum of the Board Price
我想做的是使用上述查询中的信息(特别是董事会英尺总和)填充文本框
我是VBA编码的新手,因此无法确定我是否应该寻找。帮助将不胜感激
很可能您最好在文本框的表达式中使用DSum,例如:
=DSum("[NameOfYourFieldWithBoardPrice]","[YourOrderDetailsTable]","[OrderID]=" & [Forms]![FMain_Orders]![OrderID] & "")
或者,如果文本框位于FMain Orders上:
=DSum("[NameOfYourFieldWithBoardPrice]","[YourOrderDetailsTable]","[OrderID]=" & Me![OrderID] & "")
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句