如何将子表单链接到主表单上的组合框
在访问 ADP 的表单上,有一个未绑定的组合框,用于显示公司列表(显示名称,id 是绑定字段)。选择一家公司后,我想在子表单(其数据源是companySubscription 视图)中显示该公司的订阅信息。我设置了链接主字段并将子表单的子字段属性链接到 companyId。基本上,我设置它像这样。
从理论上讲,我认为这意味着当我更改组合框中的值时,子表单应该显示该公司的订阅信息。但它不起作用 - 子表单始终显示 companySubscription 视图中的所有数据,无论组合框设置为什么。
On a form in an access ADP there is an unbound combobox that displays a list of companies (the name is shown, the id is the bound field). When a company is chosen, I want to display the subscription information in a subform (the datasource for which is companySubscription view) for that company. I set the link Master Fields and links child Fields property of the subform to the companyId. Basically, I set it up like this.
In theory, I would think this would mean that when I change the value in the combobox the subform should show the subscription information for that company. It isn't working though- the subform always shows all the data in the companySubscription view, no matter what the combobox is set to.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
找到了答案 - 来自另一个项目的一些代码有帮助:
并且必须针对 ADP 对其进行修改(感谢 此帖子!)
Found the answer- had some code from another project that helped:
And had to modify it for an ADP (thanks to this post!)