Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Compacting an Open Database using VBA

Status
Not open for further replies.

dleiba

MIS
Joined
Aug 22, 2001
Messages
28
Location
JM
Hey guys,

I am using Office XP to open an Access 2000 database (it opens in Access 2000 format by default).

I searched through previous threads and found the following command to compact my database when it is open.

SendKeys ("%(W1)")
SendKeys ("%(TDC)")

I put this code on the OnClick Event Procedure of a button on a form. However, nothing happens when I click the button.

Am I missing something?

Thanks

Dominic >(::O>
dsleiba@capital-credit.com
 
Compact on Close under Tools, Options, General.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top