本文介绍了计划任务运行宏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


我想知道是否有另一种方法可以在预定的时间运行宏?


目前我已经设置好了Windows计划任务,但每次运行时都会打开数据库然后关闭它。但是我希望能够让数据库保持打开并且仍然运行宏。


我有以下宏:


Run_Weekly - 附加到另一个表然后删除主表并打印

Run_Monthly - 与上面相同但删除每周表

Run_Yearly - 打印年度报告和删除年度表中的数据


是否可以通过VBA完成此操作?我只是不确定我指定每周,每月和每年运行一次。


可能没有一个简单的答案,但任何帮助都会受到赞赏。


谢谢你

Hi All,

I am wondering if there is another way to run macros at a scheduled time?

Current I have setup Windows Scheduled Tasks but each time they run they open the database and then close it. But I want to be able to leave the database open and still have the macros run.

I have the following Macros:

Run_Weekly - which appends into another table and then deletes the main table and prints
Run_Monthly - which does the same as above but deletes the Weekly Table
Run_Yearly - which prints the yearly report and deletes the data in the yearly table

is it possible for this to be done via VBA? I''m just not sure who I specify to run once a week, month and year.

There might not be an easy answer but any help would appreciated.

Thank You

推荐答案




这篇关于计划任务运行宏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

05-29 00:42
查看更多