If you have read my previous blog about the My namespace in Visual Basic you understand how much I like this. Well it seems so do C# developers. Juval Lowy has been busy creating a “That” class in C# that wraps up and exposes the My functionality (with limits) in C#.
Check out the iDesign site:
“The My class in VB often simplifies and streamlines many operations, from Network programming to clipboard, to audio access, and so on. What takes sometimes a programming fit in C# can be done in one line using the My class in VB. If VB has Me and My, then C# should have this and That. The That class is the C# equivalent of the VB My class. It is a static class that uses the VB implementation as much as possible, and it requires adding a referencing to Microsoft.VisualBasic. The That class is instrumental when working in heterogeneous environments and when dealing with in porting of VB to C# or visa-versa.”
My favorite line "What takes sometimes a programming fit in C# can be done in one line using the My class in VB." Then again that is just my VB colors showing.
I think this is a great example of the fact that VB and C# aren’t mortal enemies as some people would make them appear to be, they are different products targeting different groups of developers. Good ideas flow both ways, innovation is alive and well in the Visual Basic world and the C# world. Both languages have a bright future ahead.