How are you trying to open the database?
If you're trying to use Automation, take a look at the kludge approach
outlined in section "Bypassing Startup Settings When Opening a Database" in
http://support.microsoft.com/kb/147816/ (Don't worry that it says Access 97:
it applies to all versions). The reason I call it a kludge is that it uses
SendKeys, which is seldom recommended in product grade applications.
--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)
"Anthony" <(E-Mail Removed)> wrote in message
news:OYXyH$(E-Mail Removed)...
> Okay, thank you!
>
> Now how do I programmatically cause that database to bypass startup
> (AutoExec Macro and Startup object)?
>
>
> "Douglas J. Steele" <NOSPAM_djsteele@NOSPAM_canada.com> wrote in message
> news:(E-Mail Removed)...
>> CompactOnClose is an application property, not a database property. You'd
>> set it using
>>
>> Application.SetOption "Auto Compact", -1
>>
>> Note, though, that it doesn't do anything with external databases: it
>> only applies to the database you've currently got open.
>>
>>
>> --
>> Doug Steele, Microsoft Access MVP
>> http://I.Am/DougSteele
>> (no private e-mails, please)
>>
>>
>> "Anthony" <(E-Mail Removed)> wrote in message
>> news:%(E-Mail Removed)...
>>> Is there a way to use VBA to programatically enable/disable the
>>> "CompactOnClose" property of an external database?
>>>
>>>
>>>
>>>
>>
>>
>
>