Click here to Skip to main content
15,885,213 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
C#.net and VB.net, which one is better and why it is better?
I am thinking about learning one of these languages, can you guys tell me what are the advantages and disadvantages of these languages and which one should I choose?

What I have tried:

I personally think Visual basic is better when I will go for a job, but I am not sure.
Posted
Updated 17-Dec-20 19:27pm
Comments
[no name] 14-Feb-17 10:13am    
Neither one is better than the other.
Richard Deeming 14-Feb-17 11:03am    
There is no such thing as "C#.net" - it's simply called "C#".

VB.NET has the ".NET" suffix to differentiate it from the older VB language, which ran from v1 in 1991 to v6 in 1998.

C# didn't exist before the .NET Framework, so it didn't need the ".NET" suffix.

Learn C# since most examples online in articles and blog posts are in C#. VB.Net and C# are very similar in syntax so if you do find a VB.Net article you can easily convert it into C#.

I actually started out with VB.Net before I did C# and it was very easy to transition to C#.
 
Share this answer
 
When you will go for a job in Programming then C# will be the better choice.
If you first want to learn then VB could be the better choice - it depends on what is better readable for you.
In both cases : what you have to learn is not the programming-language - what you have to learn is the use of the .Net-Framework, the use and the sense of the different types of objects and how they come together. This part is independent from the programming-language because both languages work with it in the same way AND (as described by RyanDev) C# could be easily converted to VB and the other way round ...
 
Share this answer
 
It's obviously a bit subjective as to which is better but I suspect that most people who know both would express a preference for C#. I certainly do, it's much nicer syntactically and generally nicer to work with.

If you're thinking in terms of employment prospects, C# would be the clear winner. It's much more in demand and you're more likely to wind up working on new projects rather than supporting legacy code. I can't see VB being around for anything like as long as C#.

If you know C#, it'd be a lot easier to pick up other languages like Java, C and C++. VB is somewhat idiosyncratic and whilst it might be a good springboard to C# it won't really help you with non .NET languages.

I'd also underline RyanDev's point that there is far more community support for C#. That's a very important factor.
 
Share this answer
 
Comments
F-ES Sitecore 14-Feb-17 11:36am    
> I can't see VB being around for anything like as long as C#.

VB has been going for 25 years, c# 17 :) Given the number of production systems that use vb.net I can't see it being dropped any time soon.
PeejayAdams 14-Feb-17 11:46am    
That's an 8 year instant advantage for C#! Most languages hang around for a long, long time (I know a couple of people who still work with COBOL which is all the proof we could ever need) but I would imagine that there are far more green-field developments been undertaken in C# than there are in VB.
Ralf Meier 14-Feb-17 14:40pm    
I don't agree with you.
Both languages are compiled to the same CLR-Code. If I have a DLL which is build up with C# it is no problem to refactor it to a VB Source-Code. The common part is the Framework in the Background - not the language in front ...
PeejayAdams 15-Feb-17 4:56am    
The question asked which of the two languages is better to learn not where their commonality lies.
Ralf Meier 15-Feb-17 5:42am    
I have replied to your last reply - not to the question.
To that Point I have written something in my Solution (2) ...
Quote:
C#.net and VB.net, which one is better and why it is better?

The answer is subjective.
For learning purpose, I prefer VB, because of lack of cryptic syntax, the source code is easier to read for newbie.
For a job, C# will be more in demand.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900