Mohammad Hamdy Ghanem
Mohammad Hamdy Ghanem
I am not trying to solve anything, but the question of the language existence itself: VB ot not VB; this is the problem! In fact, VB6 does it all. Even...
1. VB.NET are hard for beginners as is. 2. Beginners should start with Small Basic not VB.NET. It lakes a form designer with a few set of controls to a...
Too symbolic. Try use keywords to express them to be a VB style.
Until now, Enum can't be a type param constraint. This can work today: ```VB.NET Module Flags Public Function [Set](e As [Enum], ParamArray flags() As [Enum]) As [Enum] If flags Is...
True. Needs type checking. This was a quick example.
@ Nice, but this is not the perfect performance. I wrote this because it is the only way not the best way: `e = DirectCast(CTypeDynamic(CTypeDynamic(Convert.ToInt64(e) + Convert.ToInt64(flag), e.GetType.GetEnumUnderlyingType), e.GetType), [Enum])`...
The true solution for this issue is to crate a Flag class. And to avoid generics and base class issues, each Flag class should be a full stand alone class,...
For starters, MyFlag should be a value-type (i.e. Structure MyFlag) and not a reference-type. > Using structures is impossible here. The Falg class is immutable (all methods returns a new...
> is a small part .... Small indeed: ```VB.NET Public Shared Widening Operator CType(value As Integer) As MyFlag Return New MyFlag(value) End Operator Public Shared Narrowing Operator CType(flag As MyFlag)...
@pricerc I am covering my bases. This is an auto generated, for a general purpose use, so, someone can decide for some reason to use the Flag as an Integer...