Shekhar_Pro
Shekhar_Pro

Reputation: 18430

VisualBasic.Net vs Visual C#

Frequently i have to program in VB.Net and Visual C#, so it would be helpful if someone can provide with a list of Refrence for Classes of in VB.net and C#.

I mean like

My.Computer.Registry in VB Maps to Microsoft.Win32.Registry in C#.

Similarly i want a refrence of other classes.

Upvotes: 1

Views: 283

Answers (1)

Allon Guralnek
Allon Guralnek

Reputation: 16141

In your example, you can use the latter in both C# and VB.NET. The former is a VB.NET "crutch" (or "shortcut", to put it nicely) so that VB developers can find stuff via IntelliSense, and are contained within a special assembly used in VB (but that can also needlessly be referenced from C#). My suggestion: don't use "My.*", use the real classes that are available from any .NET language (incl. C#) - it will make moving between languages easier and you will be able to ask BCL questions more clearly on SO.

Upvotes: 4

Related Questions