Betreft: RE: [AccessD] mdb speed

marcel.vreuls at achmea.nl marcel.vreuls at achmea.nl
Tue Oct 21 03:53:42 CDT 2003


John,

Yes, it improves the performance a lot. I also run this code in the FE for
local tables.

Gr. marcel




"John Colby" <jcolby at colbyconsulting.com>@databaseadvisors.com op
20-10-2003 17:44:05

Antwoord aub aan Access Developers discussion and problem solving
      <accessd at databaseadvisors.com>

Verzonden door:     accessd-bounces at databaseadvisors.com


Aan:  "Access Developers discussion and problem solving"
      <accessd at databaseadvisors.com>
cc:

Onderwerp:     RE: [AccessD] mdb speed


I assume this has to be inserted into a module in the BE and run with the
BE
open?

John W. Colby
www.colbyconsulting.com

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Kath Pelletti
Sent: Monday, October 20, 2003 8:56 AM
To: AccessD at databaseadvisors.com
Subject: [AccessD] mdb speed


I deleted the message from marcel(?) too fast - but Marcel here is some
code
previously posted to the list to turn off all subdatasheets in your tables,
ie. to set the name of the subdatasheet name to "None".
(Sorry - can't credit original author...)

Marcel - there have been some really good posts to the list on speed and
performance issues - maybe a search for 'speed' in the archives would be of
some help to you?

Kath

Function TurnOffSubDataSheets()
  Dim MyDB As DAO.Database
  Dim MyProperty As DAO.Property

  Dim propName As String
  Dim PropType As Integer
  Dim propVal As String

  Dim strS As String

  Set MyDB = CurrentDb

  propName = "SubDataSheetName"
  PropType = 10
  propVal = "[NONE]"

  On Error Resume Next

  For I = 0 To MyDB.TableDefs.Count - 1

     If (MyDB.TableDefs(I).Attributes And dbSystemObject) = 0 Then

        If MyDB.TableDefs(I).Properties(propName).Value <> propVal Then
           MyDB.TableDefs(I).Properties(propName).Value = propVal
           intChangedTables = intChangedTables + 1
        End If

        If Err.Number = 3270 Then
           Set MyProperty = MyDB.TableDefs(I).CreateProperty(propName)
           MyProperty.Type = PropType
           MyProperty.Value = propVal
           MyDB.TableDefs(I).Properties.Append MyProperty
        Else
           If Err.Number <> 0 Then
              MsgBox "Error: " & Err.Number & " on Table " _
              & MyDB.TableDefs(I).Name & "."
              MyDB.Close
              Exit Function
           End If
        End If

     End If
  Next I

MsgBox "The " & propName & _
" value for all non-system tables has been updated to " & propVal & "."

MyDB.Close

End Function




Kath Pelletti
Software Design & Solutions Pty Ltd.
Ph: 9505-6714
Fax: 9505-6430
sdssoftware at optusnet.com.au
_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



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


*****************************************************************
Dit bericht is bij binnenkomst gecontroleerd op de
aanwezigheid van virussen. Er zijn geen (bekende)
virussen gevonden.  Active
*****************************************************************






********************* DISCLAIMER *********************
De informatie in dit e-mail bericht is uitsluitend
bestemd voor de geadresseerde. Verstrekking aan
en gebruik door anderen is niet toegestaan.
Door de electronische verzending van het bericht
kunnen er geen rechten worden ontleend aan de
informatie.
************************************************************



More information about the AccessD mailing list