Results 1 to 4 of 4
  1. #1
    kdbailey is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2012
    Posts
    228

    Scheduled task to open a database and run a macro

    I have a ".bat" file that I am running as a scheduled task, but it will not find the database if it has spaces in it. This is my file:

    C:
    CD\Program Files\Microsoft Office\OFFICE11
    MSACCESS.EXE S:\shared\Quality\PQG\RT_Warranty_Database_Backup. mdb /x Overnight



    But when the database reads "RT Warranty Database.mdb" the execution only looks for "RT.mdb"
    How do I get this to go through without having to rename the database?

  2. #2
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    Try enclosing your full path and database name in double-quotes (and get rid of the space between your period and file extension), i.e.
    "S:\shared\Quality\PQG\RT Warranty Database Backup.mdb"

  3. #3
    kdbailey is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2012
    Posts
    228
    That space between the extention was a typo, I will give that a try in a minute.

  4. #4
    kdbailey is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2012
    Posts
    228
    Worked, thanks!

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 17
    Last Post: 05-02-2013, 11:34 AM
  2. Database Design: Normalize daily scheduled time
    By Lorlai in forum Database Design
    Replies: 1
    Last Post: 03-12-2013, 12:26 PM
  3. Replies: 4
    Last Post: 08-25-2012, 10:30 PM
  4. Replies: 0
    Last Post: 06-19-2012, 05:20 AM
  5. Help with Table Design for Employee Task Database
    By shelbsassy in forum Database Design
    Replies: 6
    Last Post: 04-08-2011, 05:14 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums