Refer to objects in expressions

An expression is a formula or calculation that you can use to obtain a result. Frequently, you must refer to objects in your database from an expression to return a value.

For example, you might need to refer to:

The value of a control or property

You refer to the value of a control or property in an expression by typing its identifier.

To refer to the value of a control

To refer to the value of a property

Notes

A form, report, subform, or subreport

You refer to an open form or report, or the subform or subreport of an open form or report, in an expression by typing its identifier.

To refer to an open form or report

To refer to a subform or subreport

Refer to the subform or subreport control on the form or report that contains the subform or subreport, then use the Form or Report property of the control to refer to the actual subform or subreport.

Notes

A form or report section or report group level

Notes

A column in a list

You can refer to a column in a multiple-column list box or combo box by using the Column property of the list box or combo box control.

Note   When you run a macro or Microsoft Visual Basic for Applications code containing an expression that refers to a form or report, the form or report must be open.