可以“ docmd.runcmd accmdnewobject ...”延迟直到对象定义?
VBA过程
DoCmd.RunCommand acCmdNewObjectDesignTable
我有一个用于创建表的 。当定义表时,它将使用
DoCmd.RunCommand acCmdNewObjectForm
基于先前创建的表创建表单。
如何延迟创建表格直到定义表之后?
建议我在运行DOCMD后检查TDF的存在以定义表。问题仍然是:如何将检查延迟到DOCMD完成后?
虽然VBA不是多线程,但“ docmd”是。
您可以通过比较创建之前和之后的全尺寸来获取名称。
I have a VBA procedure that uses
DoCmd.RunCommand acCmdNewObjectDesignTable
to create a table. When the table is defined it then uses
DoCmd.RunCommand acCmdNewObjectForm
to create a form based on the table previously created.
How to delay creatng the form until after the table has been defined?
It was suggested that I check for the existence of the TDF after running DoCmd to define the table. The questions still is: How to delay checking until after DoCmd completes?
While VBA is not multi-threaded, "DoCmd" is.
You can get the name by comparing AllTables before and after the create.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论