[AccessD] Compact on close via code

John Skolits JSkolits at CorporateDataDesign.com
Thu Apr 10 07:20:26 CDT 2003


You can find out what the checkbox is set to using the following.:

Application.GetOption("Auto Compact")

To set the flag on or off, use:

Application.SetOption "Auto Compact", True
Application.SetOption "Auto Compact", False

There is another argument for the SetOption function called "Auto Compact
Percentage" but I've never seen it work.

You can get info if you search the online help for 'Compact', and select
"Set Options from Visual Basic"

John

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Tracy
Sent: Thursday, April 10, 2003 4:22 AM
To: accessd at databaseadvisors.com
Subject: [AccessD] Compact on close via code


Hi Listers
I know theres a checkbox for compacting on close, but is there a code
equivalent that can be put into an MDE file, my users have the runtime
version of Access 2000, all bypassing of the startup options are disabled,
so I need to put code into the close procedure of the mde.
Can anybody help ?

And also it must be without user intervention as happens when the compact on
close checkbox is checked.

Thanks Tracy


_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



More information about the AccessD mailing list