ACC: DefaultEditing Property Replaced in MS Access 95 and 97

ID: Q131587


The information in this article applies to:


SUMMARY

Moderate: Requires basic macro, coding, and interoperability skills.

You cannot access the DefaultEditing form property in the Microsoft Access 7.0 and 97 user interface. Instead, you can use the new AllowEdits, AllowDeletions, AllowAdditions, and DataEntry properties.

DefaultEditing is still available programmatically to maintain backward compatibility; however, it is strongly encouraged that you use the new form properties. Programmatic changes to DefaultEditing will map to and alter the appropriate new form properties listed above. (See the "How the DefaultEditing Property Settings Map to the New Form Properties" section later in this article.)


MORE INFORMATION

Microsoft Access 7.0 and 97 use the following four properties instead of the DefaultEditing property:


   AllowEdits:     Determines whether existing records are read-only or
                   if you can edit them.

   AllowDeletions: Determines whether you can delete existing records.

   AllowAdditions: Determines whether you can add new records.

   DataEntry:      Determines whether the form shows only the new record
                   row for adding new records, or whether the form also
                   shows the existing records.
 

These new form properties make it easier to change a form's editing properties. You can use these new properties to set combinations of editing properties for a form that are not possible in Microsoft Access version 2.0.

For example, in Microsoft Access 2.0, you cannot view existing records without the ability to modify them and at the same time add new records. In Microsoft Access 7.0 and 97, you can do both by setting the following properties:

   AllowEdits:     No
   AllowDeletions: No
   AllowAdditions: Yes
   DataEntry:      No 

How the DefaultEditing Property Settings Map to the New Form Properties

The following table summarizes how the DefaultEditing property settings map to the new form properties:

   DefaultEditing   AllowEdits  AllowDeletions  AllowAdditions DataEntry
   Setting
   ----------------------------------------------------------------------
   Allow Edits      Yes         Yes             Yes             No
   Read Only        No          No              No              No
   Data Entry       Yes         Yes             Yes             Yes
   Can't Add
     Records        Yes         Yes             No              No 

If you make changes to the new form properties programmatically, the DefaultEditing property reflects the new editing settings. However, if you set a combination of the new properties that does not map directly to a DefaultEditing property setting, the DefaultEditing property defaults to AllowEdits. Therefore, you should not rely on the DefaultEditing property if you want use the new form properties. Instead, use the new form properties in Microsoft Access 7.0 and 97 applications.


Keywords          : kbusage FmsProp 
Version           : 7.0 97
Platform          : WINDOWS 
Issue type        : kbinfo 

Last Reviewed: April 30, 1999