PC Review


Reply
Thread Tools Rate Thread

Unable to run acCmdCompactDatabase

 
 
=?Utf-8?B?Q2hhc2U=?=
Guest
Posts: n/a
 
      12th Jan 2006
I want to automate the compact database process with VBA code
DoCmd.RunCommand acCmdCompactDatabase. All I get is an error message telling
me to run this function from the toolbar manually.

How do I automate so it runs on closing the database?
 
Reply With Quote
 
 
 
 
Douglas J Steele
Guest
Posts: n/a
 
      12th Jan 2006
What version of Access are you using? All versions since Access 2000 allow
you to set a Compact On Close property under Tools | Startup

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


"Chase" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I want to automate the compact database process with VBA code
> DoCmd.RunCommand acCmdCompactDatabase. All I get is an error message

telling
> me to run this function from the toolbar manually.
>
> How do I automate so it runs on closing the database?



 
Reply With Quote
 
 
 
 
Dane Cooper
Guest
Posts: n/a
 
      24th Feb 2006
Douglas:

I am running Access 2003, and this option isn't available under Tools |
Startup. Am I missing something?

Dane


"Douglas J Steele" <NOSPAM_djsteele@NOSPAM_canada.com> wrote in message
news:(E-Mail Removed)...
> What version of Access are you using? All versions since Access 2000 allow
> you to set a Compact On Close property under Tools | Startup
>
> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele
> (no e-mails, please!)
>
>
> "Chase" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> I want to automate the compact database process with VBA code
>> DoCmd.RunCommand acCmdCompactDatabase. All I get is an error message

> telling
>> me to run this function from the toolbar manually.
>>
>> How do I automate so it runs on closing the database?

>
>



 
Reply With Quote
 
Douglas J Steele
Guest
Posts: n/a
 
      24th Feb 2006
Sorry, I only have Access 97 installed on this machine, so I can't
double-check exactly where on the form it is. Have you looked under
Advanced?

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


"Dane Cooper" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Douglas:
>
> I am running Access 2003, and this option isn't available under Tools |
> Startup. Am I missing something?
>
> Dane
>
>
> "Douglas J Steele" <NOSPAM_djsteele@NOSPAM_canada.com> wrote in message
> news:(E-Mail Removed)...
> > What version of Access are you using? All versions since Access 2000

allow
> > you to set a Compact On Close property under Tools | Startup
> >
> > --
> > Doug Steele, Microsoft Access MVP
> > http://I.Am/DougSteele
> > (no e-mails, please!)
> >
> >
> > "Chase" <(E-Mail Removed)> wrote in message
> > news:(E-Mail Removed)...
> >> I want to automate the compact database process with VBA code
> >> DoCmd.RunCommand acCmdCompactDatabase. All I get is an error message

> > telling
> >> me to run this function from the toolbar manually.
> >>
> >> How do I automate so it runs on closing the database?

> >
> >

>
>



 
Reply With Quote
 
Douglas J. Steele
Guest
Posts: n/a
 
      24th Feb 2006
My fault. It's on the General tab under Tools | Options.

Note that this is setting is for all databases, not just one.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)


"Douglas J Steele" <NOSPAM_djsteele@NOSPAM_canada.com> wrote in message
news:uzJtg$(E-Mail Removed)...
> Sorry, I only have Access 97 installed on this machine, so I can't
> double-check exactly where on the form it is. Have you looked under
> Advanced?
>
> --
> Doug Steele, Microsoft Access MVP
> http://I.Am/DougSteele
> (no e-mails, please!)
>
>
> "Dane Cooper" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Douglas:
>>
>> I am running Access 2003, and this option isn't available under Tools |
>> Startup. Am I missing something?
>>
>> Dane
>>
>>
>> "Douglas J Steele" <NOSPAM_djsteele@NOSPAM_canada.com> wrote in message
>> news:(E-Mail Removed)...
>> > What version of Access are you using? All versions since Access 2000

> allow
>> > you to set a Compact On Close property under Tools | Startup
>> >
>> > --
>> > Doug Steele, Microsoft Access MVP
>> > http://I.Am/DougSteele
>> > (no e-mails, please!)
>> >
>> >
>> > "Chase" <(E-Mail Removed)> wrote in message
>> > news:(E-Mail Removed)...
>> >> I want to automate the compact database process with VBA code
>> >> DoCmd.RunCommand acCmdCompactDatabase. All I get is an error message
>> > telling
>> >> me to run this function from the toolbar manually.
>> >>
>> >> How do I automate so it runs on closing the database?
>> >
>> >

>>
>>

>
>



 
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
Cannot run exe to debug DLL in VS.NET 2003 - Unable to start debugging. Unable to start program. - Why??? Bob Rock Microsoft VC .NET 6 2nd Nov 2006 09:57 AM
Can't Run Code using Run>Run Sub/User Form =?Utf-8?B?VFc=?= Microsoft Access VBA Modules 3 16th Aug 2005 04:35 PM
MSKSrvr.exe continues to run and run and run after opening Outlook =?Utf-8?B?Zmx5aW5naHVsbHNj?= Microsoft Outlook Discussion 1 22nd May 2005 06:39 PM
Unable to run msconfig from Start-run Wil VonMayr Windows XP Performance 1 11th Mar 2004 04:42 AM
Re: Unable to run IE from Run command in Start Menu Donald McDaniel Windows XP Help 0 14th Jan 2004 03:43 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:16 PM.