Results 1 to 6 of 6

Thread: access autorecovery

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Jul 2006
    Location
    nasik,india
    Posts
    909

    access autorecovery

    I have an application in vb and access.
    is there any solution to compact-repair access database automatically when no user is accessing software.
    WHETHER YOU SUCCEED OR FAIL IS NOT AS IMPORTANT AS WHETHER YOU TRIED YOUR BEST

  2. #2
    Banned randem's Avatar
    Join Date
    Oct 2002
    Location
    Maui, Hawaii
    Posts
    11,385

    Re: access autorecovery

    Automatically... No. You would have to write a function to determine when no one is using it and compact it then.

  3. #3
    Lively Member
    Join Date
    Mar 2007
    Posts
    124

    Re: access autorecovery

    Maybe you can copy the database sort of backup to a different folder. Then do the compact and repair there. Once your done, overwrite it to the main database.

  4. #4

    Thread Starter
    Fanatic Member
    Join Date
    Jul 2006
    Location
    nasik,india
    Posts
    909

    Re: access autorecovery

    no i want some automatic repairing..or i will give a time at which no-one is using software.
    WHETHER YOU SUCCEED OR FAIL IS NOT AS IMPORTANT AS WHETHER YOU TRIED YOUR BEST

  5. #5
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: access autorecovery

    Quote Originally Posted by shukla
    no i want some automatic repairing..or i will give a time at which no-one is using software.
    Then I would suggest following this advice
    Quote Originally Posted by randem
    Automatically... No. You would have to write a function to determine when no one is using it and compact it then.

  6. #6
    PowerPoster
    Join Date
    Feb 2006
    Location
    East of NYC, USA
    Posts
    5,691

    Re: access autorecovery

    Or require users to log into and out of your program. You could do a compact on logout, and if anyone tries to log in while you're compacting, you could raise a message box telling them that the database is undergoing auto compact and repair and they'll have to wait. If you have an idea how long your normal compact takes you could even start a timer when you start compacting and tell them about how much longer it will be until they can log in.

    Or you could reset a timer at every keystroke and, if the timer runs out (you'd have to determine how long you'll allow a user to stare at the screen before you consider him to be "not using" the database) you run your compact and repair, locking the user out until it's done.
    The most difficult part of developing a program is understanding the problem.
    The second most difficult part is deciding how you're going to solve the problem.
    Actually writing the program (translating your solution into some computer language) is the easiest part.

    Please indent your code and use [HIGHLIGHT="VB"] [/HIGHLIGHT] tags around it to make it easier to read.

    Please Help Us To Save Ana

Posting Permissions

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



Click Here to Expand Forum to Full Width