scheduling a macro in word

T

Tom Fries

Hi I am using windows XP And Office XP. I have a document created in
Microsoft Word called Monthly News.doc . It is obviously a monthly
newsletter for my company. Each month I send it out as a mail merge to 250
people on my mailing list. I have a macro called Send_news that
automatically prints this merge out.

I want to schedule this event so that it runs automatically on the 30th of
each month whether I am there or not. I want it to open the document monthly
news and start the macro called send_news and then close word when it is
completed.

Can you help me with the visual basic code or can this be done in an easier
method?

Thanks
 
P

Peter

As long as your computer is going to be turned on and logged in on the 30th, you can create a scheduled event that will run Word, specifying the macro name and document to open.
http://support.microsoft.com/kb/q210565/
The command would be something like

"C:\Program files\Microsoft Office\Office11\WinWord.exe /msend_news "monthly news.doc""

At the end of send_news(), put an Application.Quit command.

hth,

-Peter

btw, I'm not completely sure you need to be logged in for the scheduled event to run, might depend on whether it runs as a system event or not...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top