ActiveDataAccessPage Property

Microsoft Access Visual Basic

ActiveDataAccessPage Property

       

You can use the ActiveDataAccessPage property to identify or refer to the data access page that has the focus. Read-only DataAccessPage object.

expression.ActiveDataAccessPage

expression   Required. An expression that returns one of the objects in the Applies To list.

Setting

The ActiveDataAccessPage property setting contains a reference to the DataAccessPage object that has the focus at run time.

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

Remarks

Use the ActiveDataAccessPage property to refer to an active data access page together with one of its properties or methods. The following example displays the Name property setting of the active data access page:

Dim pgCurrentPage As DataAccessPage
Set pgCurrentPage = Screen.ActiveDataAccessPage
MsgBox "Current Data Page is " & pgCurrentPage.Name

If no data access page has the focus when you use the ActiveDataAccessPage property, an error occurs.