PC Review


Reply
Thread Tools Rate Thread

Compact & Repair on the fly...

 
 
Steven M. Britton
Guest
Posts: n/a
 
      22nd Jun 2004
Here is the code to add to VB.

Private Sub CompactDB_Click()
On Error GoTo Err_CompactDB_Click

CommandBars("Menu Bar"). _
Controls("Tools"). _
Controls("Database utilities"). _
Controls("Compact and repair database..."). _
accDoDefaultAction

Exit_CompactDB_Click:
Exit Sub

Err_CompactDB_Click:
MsgBox Err.Description
Resume Exit_CompactDB_Click

End Sub

-Steve

>-----Original Message-----
>Hi!
>
>Does anyone know how to programmatically compact and

repair the database on the fly? I have a database where
I'm creating and deleting tables and its size swells
quickly until I compact and repair manually.
>
>Thanks a lot for any help!
>
>Dan
>.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Compact And Repair FP1 Microsoft Access Form Coding 6 7th Sep 2007 08:33 PM
Stopping Compact and Repair (and Compact on Close) - Records Disappear gee664@gmail.com Microsoft Access 7 25th Apr 2006 05:17 PM
Compact and Repair =?Utf-8?B?SlQ=?= Microsoft Access VBA Modules 1 3rd Aug 2005 03:42 PM
compact and repair Tig Microsoft Access 1 4th Dec 2004 12:50 PM
Repair and compact allie Microsoft Access Form Coding 0 26th Apr 2004 12:56 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:02 AM.