Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Jan 2002
    Location
    Trenton, Ontario
    Posts
    175
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Automatically Open Workbook (2000)

    Assuming I have Excel running, is it possible to have a workbook open automatically at a given time every day, update (using MS Query), save itself and then close? And if that is possible, can it also be done once a week.
    I have a number of reports that I have set up to update on opening using MS Query that get forwarded on to different customers and I'm hoping to automate them.
    Thanks in advance for any help you can provide.
    Stats

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Automatically Open Workbook (2000)

    Look into the OnTime method. Example usage:

    Application.OnTime TimeValue("5:00 PM"), "MyMacro"

    The macro named MyMacro should do the things you want (open a workbook, update, save and close it).

    You can have more than one OnTime action scheduled.

  3. #3
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    South Carolina, USA
    Posts
    7,295
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Automatically Open Workbook (2000)

    If you don't have Excel running, then you can use the Windows Scheduler to schedle the Workbook to run at the same time every day. The scheduler will start Excel and open the workbook on the schedule you specify.

    If you are positive that Excel will be running, then you can use the technique HansV gave you.
    Legare Coleman

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •