A data member is a variable that is a member of a type. The Dim
modifier is equivalent to the default access modifier for the declaration and must be specified if no access modifier is specified. Each data member declarator introduces a new member. If an initializer is specified, only one data member may be declared by the data member declaration.
If the declarator contains an As
clause, then the clause specifies the type of the members introduced by the declaration; if the type is omitted, the type of the members is implicitly Object
. The accessibility domain of a data member's type or array element type must be the same as or a superset of the accessibility domain of the data member itself.
Shared
| Dim
As
TypeName ]As
[ New
] TypeName [ (
FormalParameterList )
] ] [ = VariableInitializer ],
DataMemberIdentifierReadOnly
| WithEvents