CurrentView Property

CurrentView property as it applies to the AccessObject object.

Returns the current view for the specified Microsoft Access object. Read-only AcCurrentView.

AcCurrentView can be one of these AcCurrentView constants.
acCurViewDatasheet
acCurViewDesign
acCurViewFormBrowse
acCurViewPivotChart
acCurViewPivotTable
acCurViewPreview

expression.CurrentView

expression   Required. An expression that returns an AccessObject object.

CurrentView property as it applies to the DataAccessPage object.

You can use the CurrentView property to determine how a data access page is currently displayed. Read-only Integer.

expression.CurrentView

expression   Required. An expression that returns a DataAccessPage object.

CurrentView property as it applies to the Form object.

You can use the CurrentView property to determine how a form is currently displayed. Read/write Integer.

expression.CurrentView

expression   Required. An expression that returns a Form object.

Settings

The CurrentView property uses the following settings.

Setting Form Displayed In: Data Access Page Displayed In:
0 Design view Design view
1 Form view Page view
2 Datasheet view Not applicable

This property is available only by using a macro or Visual Basic and is read-only in all views.

Remarks

Use this property to perform different tasks depending on the current view. For example, an event procedure could determine which view the form is displayed in and perform one task if the form is displayed in Form view or another task if it's displayed in Datasheet view.