DataEntry Property

Applies To

Form.

Description

You can use the DataEntry property to specify whether a bound form opens to allow data entry only. The Data Entry property doesn't determine whether records can be added; it only determines whether existing records are displayed.

Setting

The DataEntry property uses the following settings.

Setting

Description

Visual Basic

Yes

The form opens showing only a blank record.

True (–1)

No

(Default) The form opens showing existing records.

False (0)


You can set the DataEntry property by using a form's property sheet, a macro, or Visual Basic.

This property can be set in any view.

Remarks

The DataEntry property has an effect only when the AllowAdditions property is set to Yes.

Setting the DataEntry property to Yes by using Visual Basic has the same effect as clicking Data Entry on the Records menu. Setting it to No by using Visual Basic is equivalent to clicking Remove Filter/Sort on the Records menu.

Note When the Data Mode argument of the OpenForm action is set, Microsoft Access will override a number of form property settings. If the Data Mode argument of the OpenForm action is set to Edit, Microsoft Access will open the form with the following property settings:

  • AllowEdits — Yes
  • AllowDeletions — Yes
  • AllowAdditions — Yes
  • DataEntry — No
To prevent the OpenForm action from overriding any of these existing property settings, omit the Data Mode argument setting so that Microsoft Access will use the property settings defined by the form.

See Also

AllowAdditions property, AllowDeletions property, AllowEdits property, Enabled, Locked properties, OpenForm action, OpenForm method, RecordsetType property.