Saturday August 1st

Friday July 31st

Thursday July 30th

Wednesday July 29th

1 Kicks

How to prevent Extension methods from appearing as global functions

C# have static (or shared) classes which VB lacks. Instead VB uses modules which are almost the same thing. One thing differs though and that is that modules makes its public methods appear as global accessible functions, meaning you don’t have to type the ModuleName.MethodName() when calling such a member. You can instead simply call MethodName() directly. A disadvantage of this fact is that extension methods, that must exist in modules in VB, will appear in IntelliSense as global functions and not only as a method of the type you extended.

0 comments

Commenting on Stories is limited for now and will open up to those recommended by the community. Learn how
Loading DotNetKicks...
brought to you by the Kicks Network