问题描述
我有一个表格''frmHome''。它有一个标签控件''tabCtrl''。选项卡控件有两种形式:''frmContacts''和''frmProjects''。
在联系表单上,我可以看到一个人参与的项目。在项目表单中,我可以看到与项目相关联的人员。
我想从联系人表单中点击项目,然后让我把它带到项目表单上的那个项目。我想同样点击项目表单上的某个人,然后将它带到联系表单上的那个人。
到目前为止,我可以通过dbl点击一个项目联系人表单,代码将使用项目表单将选项卡控件更改为适当的页面。此外,项目页面上有一个public sub,它将当前记录设置为全局变量的值。我用命令按钮测试了那个sub,它运行得很好。
但是我无法弄清楚如何从另一种形式调用那个公共子。我无法弄清楚引用它的正确语法。
帮助?谢谢。
I have a form ''frmHome''. It has a tab control ''tabCtrl''. The tab control has two forms: ''frmContacts'' and ''frmProjects''.
On the contacts form I can see the projects a person is involved with. On the Projects form I can see the people associated with a project.
I want to dbl-click on a project from the contacts form, and have it take me to that project on the projects form. I want to similarly click a person on the projects form, and have it take me to that person on the contacts form.
So far, I can dbl-click on a project in the contacts form, and the code will change the tab control to the appropriate page with the projects form. Also, there is a public sub on the projects page which will set the current record to the value of a global variable. I tested that sub with a command button and it works great.
BUT - I can''t figure out how to call that public sub from the other form. I can''t figure out the proper syntax to reference it.
Help? Thanks.
推荐答案
这篇关于如何在同一个选项卡控件中调用另一个表单上的subs?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!