John Bartow
john at winhaven.net
Fri May 2 12:32:39 CDT 2003
Mark, Go ahead and post the code on the list. I think it would be a valuable thing to add. And then you won't get a bunch of Mee2s. JB PS: otherwise Mee2 > -----Original Message----- > From: accessd-bounces at databaseadvisors.com > [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Mark A Matte > Sent: Friday, May 02, 2003 11:18 AM > To: accessd at databaseadvisors.com > Subject: RE: [AccessD] Compact DB > > > Ryan, > > If it is in A97 I have a sample DB that compacts on close if it > is only open > once...and if it is above a certain size. It also uses the > sendkey method. > > Please contact me OFFLINE(not thru the list) if you would like a copy. > > Thanks, > > Mark A. Matte > > > > >From: "John Bartow" <john at winhaven.net> > >Reply-To: accessd at databaseadvisors.com > >To: <accessd at databaseadvisors.com> > >Subject: RE: [AccessD] Compact DB > >Date: Fri, 2 May 2003 10:04:07 -0500 > > > >Compact DBIt depends. A2k and > has it on the Tools menu. For > A97 use this: > > > >Public Sub SelfCompact() > > ' Comments : A massive work around to the lack of > compact on close > >in A97. > > ' Builds a temporary Command Bar and then closes and > >reopens the DB. > > ' Code credit to Jim Dettman. Online > Computer Services > >of > >WNY, Inc. jimdettman at earthlink.net > > ' Parameters : - > > ' Returns : - > > > > On Error GoTo PROC_ERR > > > > With CommandBars.Add(, 1, , True) > > .Controls.Add 1, 2071, , , True > > .Visible = True > > .Controls(1).SetFocus > > DoEvents > > SendKeys "~" > > End With > > Exit Sub > > > >PROC_ERR: > > MsgBox "The following error occurred: " & Error$ > > Resume Next > >End Sub > > > >HTH > >JB > > > >-----Original Message----- > >From: accessd-bounces at databaseadvisors.com > >[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Smethurst, Ryan > >Sent: Friday, May 02, 2003 5:16 AM > >To: 'accessd at databaseadvisors.com' > >Subject: [AccessD] Compact DB > > > > > > ---- London Borough of Bromley E-Mail Disclaimer ---- > > "For information about Bromley Council visit our web site > >www.bromley.gov.uk" > > > > "The information contained in this message (including any > attachments) > >is > >confidential in that it is intended solely for the use of the > recipient to > >which it is addressed. If you are not the intended recipient, the use of > >the > >information by disclosure, copying or distribution is prohibited > and may be > >unlawful." > > > > ---- End of Disclaimer ---- > > > > Hi Group, > > > > Is it possible to compact a db in code when quitting it? > > > > Thanks > > RyanS > >_______________________________________________ > >AccessD mailing list > >AccessD at databaseadvisors.com > >http://databaseadvisors.com/mailman/listinfo/accessd > >Website: http://www.databaseadvisors.com > > > _________________________________________________________________ > The new MSN 8: smart spam protection and 2 months FREE* > http://join.msn.com/?page=features/junkmail > > _______________________________________________ > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > >