Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hi guys ... i need ur help 1

Status
Not open for further replies.

inspiredtech

Programmer
Aug 27, 2003
2
SY
i want to take MCAD.NET courses and i dont know what language should i choose.. VB.net or C# , i know c++ and a little visual basic 6 ....
some friends told me that C# is much more powefull , others said that they're the same in powefull but VB is much easier and its editer writes for you and you dont have to remember all the keywords like C# ...
So plz help me in choosing , tell me your opinion and tell me why..?
Thanx in advance ..
Mulham
 
Hi,

Each language has its own set of advantages. The entire .NET framework was written in C#, from what I understand; but in most regards, VB is easier to read. If you really *know* C++, you'd probably be more comfortable in C#. As for the editor: they work about the same... in both languages, you're using the same IDE.
 
My two cents...

C# is a great language if you are coming from a C or Java background as the syntax is very similar.

VB.NET is a great language if you are coming from a VB6/VBA background, and although there is a considerable learning curve due to the language enhancements, it is nowhere near as great as VB6/VBA to C#.

As for performance, it depends who you talk to. My understanding is that both C# and VB.NET get compiled into the same Microsoft Intermediate Language (MSIL), and it is the MSIL code that is interpreted and executed by the .NET common language runtime. So theoretically, allowing for slight differences in the compilers, the two languages should have reasonably comparable performance. Both languages also use the same framework classes, where a lot of the real work is done.

I don't code in C#, but all the samples I have seen run in both languages seem to perform the same.
 
In addition to my waffle above....

Using Option Strict can also have a positive impact on the performance of VB.NET code. By default, C# has Option Strict On, but VB.NET has Option Strict Off.

Using Option Strict On means more compact MSIL code (Option Strict forces the code to be type safe at design time, and therefore type conversions do not require evaluation to determine if they can be achieved at run time) and therefore better performance.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top