Enum Definition
Syntax
[ | Private
| Public ] _
Enum name
elem [ =
value]
[...]
End Enum
Group Declaration
Description Define a new user enum. Each elem defines an element of the enum. If value is given then that is the element's value. The value can be any constant integer expression. If value is omitted then the element's value is one more than the previous element's value. If there is no previous element then zero is used.
Access If no access is specified then Public is assumed.
Example
'#Language
"WWB-COM"
Enum Days
Monday
Tuesday
Wednesday
Thursday
Friday
Saturday
Sunday
End Enum
SubMain
Dim D As Days
For D = Monday To Friday
Debug.Print D ' 0 through 4
Next
D
End Sub