Microsoft® Excel® based database addin

 

+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    TotallyConfused Guest

    Default Scheduling a query to run

    Can you schedule a query to run in Access automatically? If so can someone
    please tell how to go about it or where I can find info how to incorporate
    this into a database. Thank you in advance for any help you can provide.
    Thank you.

  2. #2
    June7 via AccessMonster.com Guest

    Default Re: Scheduling a query to run

    Do you want to run even when the project is not open? I have read some about
    using Windows Task Scheduler to do this. Either through a .bat or .vbs file
    or directly to Access. I tried opening Access through VBScript but not having
    much luck. Here is the sample code I found:
    Set objAccess = CreateObject("Access.Application")
    objAccess.OpenCurrentDatabase "C:\filepath\mydatabase.mdb"

    Also code for .bat file (again, I can't make work):
    C:\Program Files\Microsoft Office\Office\MSAccess.exe" "C:\myDB.mdb"
    /macroname

    If you only want to do it when project is open, what would be the condition
    for initiating the action - when project opened, following data entry, time
    of day? Here is one thread to check out:
    http://www.tech-archive.net/Archive/.../msg01204.html

  3. #3
    Mark Andrews Guest

    Default Re: Scheduling a query to run

    How about just make a macro that starts the process of running the query and
    then checkout this article for
    details on how to run access with command line arguments to start the macro
    (from windows task scheduler):
    http://bytes.com/topic/access/answer...scheduled-task

    HTH,
    Mark
    RPT Software
    http://www.rptsoftware.com

Bookmarks

Posting Permissions

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