Syntax[accessModifier] Module name [statements] End Module
DescriptionThe Module...End Module statement defines a code block as a code module. A module is similar to a class where every member is Shared by default. Modules may contain fields, properties, methods, events, and other types. Usage at a Glance
Version DifferencesThe Module statement is new to VB under .NET, but the idea of a module was always part of Visual Basic. VB 6 placed each code module in a separate BAS file, which rendered beginning and ending statements unnecessary. A single VB source code file in .NET, on the other hand, can contain multiple code modules and other types. See AlsoClass...End Class Statement |