Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2003
    Location
    Belfast, UK
    Posts
    87

    Unanswered: Create copy of backend and compact

    Hi,

    does anyone know how to create a copy of a backend a compact it?
    there are a few things I'd like to do first though.
    1 - I'd like to do this all in code.
    2 - I'd like to check to make sure no other users are accessing the data (prevent data getting corrupted if other people are accessing it).
    3 - Create a backup schedule.

    All help/suggestions appreciated.

  2. #2
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1

    Re: Create copy of backend and compact

    Originally posted by bertthefreak
    Hi,

    does anyone know how to create a copy of a backend a compact it?
    there are a few things I'd like to do first though.
    1 - I'd like to do this all in code.
    2 - I'd like to check to make sure no other users are accessing the data (prevent data getting corrupted if other people are accessing it).
    3 - Create a backup schedule.

    All help/suggestions appreciated.
    To copy and compact your backend file.mdb make another .mdb in which you could use
    Shell("Copy c:\yourDB.mdb z:\Backup\yourDB_today", 1)


    Application.DBEngine.CompactDatabase "yourDB.mdb", _
    "yourDB_Backup.mdb"



  3. #3
    Join Date
    Feb 2004
    Location
    New Zealand
    Posts
    1,423
    Provided Answers: 8
    Here one i just created

    in the options click compact on close


    know in the back end database

    create a MACRO and QUIT the database

    and name it autoexec


    know with the Scheduled run it

    the Scheduled will one it and the MACRO will close and it will then get compacted
    hope this help

    See clear as mud


    StePhan McKillen
    the aim is store once, not store multiple times
    Remember... Optimize 'til you die!
    Progaming environment:
    Access based on my own environment: DAO3.6/A97/A2000/A2003/A2007/A2010
    VB based on my own environment: vb6 sp5
    ASP based on my own environment: 5.6
    VB-NET based on my own environment started 2007
    SQL-2005 based on my own environment started 2008
    MYLE
    YOUR PASSWORD IS JUST LIKE YOUR TOOTHBRUSH DON'T SHARE IT.

Posting Permissions

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