Compact And Repair

A

Alick [MSFT]

Hi Ali,

Please refer to the article to resolve the issue.

ACC: Sample Macro for Compacting and Repairing a Database
http://support.microsoft.com/?id=100923


Sincerely,

Alick Ye, MCSD
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.



--------------------
| From: "A.M" <[email protected]>
| Subject: Compact And Repair
| Date: Wed, 24 Sep 2003 12:17:10 -0400
| X-Tomcat-NG: microsoft.public.access.macros
|
| Hi,
|
| How can i compact and repair current database in a macro ?
|
| Thanks,
| Ali
|
|
|
 
S

Steve Schapel

Ali,

It is not possible to do this in a macro. If you are using Access
2000 or later version, there is a 'Compact on Close' option available
(see under the Tools menu). Otherwise you need to use VBA code to
close the current database and open another, from which you can then
compact the first. The tsiSOON utility available at
www.trigeminal.com may be of relevance.

- Steve Schapel, Microsoft Access MVP
 
A

Alick [MSFT]

Hi Ali,

Steve is right; we can't compact and repair the database via macro or VBA
code when the current database is open, which means we cannot use the
compact/repair code in a module belonging to current database. The article
100923 is used to compact/repair other mdb file instead of the current open
one. Sorry not accurately address your post.

Please feel free to let me know if you have any concerns or question.

Sincerely,

Alick Ye, MCSD
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

| From: "A.M" <[email protected]>
| Subject: Compact And Repair
| Date: Wed, 24 Sep 2003 12:17:10 -0400
|
| Hi,
|
| How can i compact and repair current database in a macro ?
|
| Thanks,
| Ali
|
|
|
 

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

Ask a Question

Top