Results 1 to 3 of 3
  1. #1
    4 Star Lounger
    Join Date
    Jun 2001
    Location
    Edinburgh, Midlothian, Scotland
    Posts
    492
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Compact & Repair (Access xp)

    Next silly question from a duffer!!!!

    Is there an easy way to do a Compact & Repair on the current database using VBA.

    I have written a routine to remove certain entries from multiple tables that have been created in error. So I want to finish with a Compact & Repair afterwards to ensure that the auto-numbers are re-set.

    The help file doesn't do much to point me in the right direction. I've read it and am more confused than I was before.

    Thanks

    Colin

    ****************************************
    Colin McDonald
    colinmac@blueyonder.co.uk
    ****************************************

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Compact & Repair (Access xp)

    Take a look at the thread starting at <post#=194515>post 194515</post#>.

  3. #3
    4 Star Lounger
    Join Date
    Jun 2001
    Location
    Edinburgh, Midlothian, Scotland
    Posts
    492
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Compact & Repair (Access xp)

    Hans

    Thanks for the response.

    I should have done a search first. I do try to remember to do a search first., but so often the varied answers make finding your specific question difficult. I did try a search after your response, and sure enough, there was the answer at the top of the pile.

    Thanks.

    Incidentally, as I'm the only user, and the "Undo" I'm trying to do could only happen once a month when I update the bank statement, and only then if I make a mistake. I think I'll simply add a message box instructing that a Compact & Repair should be done next.

    I read the page on The Access Web, and once its explained, it makes perfect sense why you can't run it from code. I took the download down and read it, but decided against it. I will not be treasurer of this group for ever, and when I hand the file over, I do not want to have to remember to install add-ins on someone else's machine.

    Thanks again, I've learned again.


    Colin

Posting Permissions

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