References to Declared Elements
When your code refers to a declared element, the Visual Basic compiler matches the name in your reference to the appropriate declaration of that name. If more than one element is declared with the same name, you can control which of those elements is to be referenced by qualifying its name.
In This Section
Resolving a Reference When Multiple Variables Have the Same Name
Discusses how the compiler matches a reference to a declaration.
How to: Qualify a Declared Element Name
Explains how to qualify an element name to facilitate a reference match.
How to: Distinguish Between Two Elements with the Same Name
Describes how to qualify an element name when calling it to enable the Visual Basic compiler to match your reference to the desired element.
Shadowing in Visual Basic
Describes the treatment of elements with the same name.