Copy Front End Dbase to Local Workstation

Discussion in 'Access Configuration' started by Dave C, Mar 20, 2010.

  1. Dave C

    Dave C Guest

    I have a batch file that:

    1 - Checks for the existence of a defined folder on the local workstation
    2 - Creates the folder of required
    3 - Copies the front end database from a shared folder on the network
    4 - Opens the front end database on the local workstation

    My problem/question is:
    The batch file runs minimised but the window remains open until either 1)
    the database is closed or 2) it is closed manually.

    Is there a way that the command window can be closed once the database opens
    as its code has been executed and I'd like to close the window rather than it
    hanging around.

    Any suggestions would be most appreciated.

    Thanks ... Dave
     
    Dave C, Mar 20, 2010
    #1
    1. Advertisements

  2. Dave C

    Dave C Guest

    No need to answer this question as I've resolved the matter. If it helps
    anyone the following works just great:

    Sample Code

    Set WshShell = CreateObject("WScript.Shell")
    WshShell.Run chr(34) & "C:\Batch Files\syncfiles.bat" & Chr(34), 0
    Set WshShell = Nothing

    Copy the lines above to Notepad and save the file with .VBS extension. Edit
    the .BAT file name and path accordingly, and save the file. Double-click the
    ..VBS file to run it.

    Regards .... Dave
     
    Dave C, Mar 21, 2010
    #2
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.