Enums

Both Access and VBA contain another structure called an enum. Short for enumeration, this structure is essentially a wrapper for a group of built-in constants. It is more of a way to categorize constants than to do anything with them. You won't actually use the enum to do anything; rather, you'll use the constants declared in the enum instead of using their intrinsic values. As you can imagine, Access has a numerous built-in enums. The following enum describes the constants that can be used to specify the view of a form.

Enum acFormView acNormal = 0 acDesign = l acPreview = 2 acFormDS = 3 acFormPivotTable = 4 acFormPivotChart = 5 acFormLayout = 6 End Enum

You can browse any of the Access or VBA enums in the Object Browser, which you learned about in Chapter 4.

Was this article helpful?

0 0

Post a comment