In principle, it has always been possible to extend classes with new methods or properties. You inherited them and then added new methods or properties in the inherited class code. This worked as long as the following conditions were met:
The types were not marked with the NotInheritable modifier (Sealed in C#).
The types weren’t value types—because types created with Structure are automatically value types and those are implicitly not inheritable.
To help structure your code better, Microsoft added extension methods in Visual Basic 2008. You can use these to add user-defined functions to already defined data types without having to create a new, inherited type. An extension method is a special kind of static method, but you can ...