0

Possible Duplicates:
What are the most important functional differences between C# and VB.NET?
C#'s edge over VB

I'm programming in VB.net because I'd former experience in VB 6.0 and I've familiar with its syntax. I know that C# is preferred by the biggest part of .net programmers. I know that C performance had superior performance against many other languages, but there is a good advantage in the same .net framework? There is a quite good reason for advicing me if should I migrate right now from VB to C#? Thanks!

Community
  • 1
  • 1
Alex
  • 3,325
  • 11
  • 52
  • 80
  • @asawyer -- I dunno, I think VB syntax is a sin :) – Matt Greer Apr 18 '11 at 21:26
  • 1
    **There is no such thing as C#.net.** – R. Martinho Fernandes Apr 18 '11 at 21:27
  • 2
    @Martinho: it's pretty pervasive. Want to hear Microsoft answer the OP's question? ["Although there are differences between Visual Basic .NET and Visual C# .NET, both are first-class programming languages..."](http://support.microsoft.com/kb/308470) – Michael Petrotta Apr 18 '11 at 21:34
  • if you look at the Tag numbers on the right you'll see about a 10:1 ratio of C# to VB.NET posts on SO. On on careers.SO its 20:1. With books and other resources its a similar story. The ecosystem treats the two very differently which I think is unfortunate. On the other hand they're so similar that if you know one it will only take 2-4 weeks to transition to the other. – Conrad Frix Apr 18 '11 at 22:36
  • @Conrad -- but the vast majority of questions tagged C# really are .NET questions where the asker just happens to be using C# as his language to describe his problem. 99 times out of 100 the question could have just as easily been asked in VB.NET. Questions that truly pertain to C# and are not relevant to VB.NET are probably a lot less. – Matt Greer Apr 19 '11 at 02:22
  • @Matt Greer I totally agree. Which is why it pays for a .NET programmer to know C# syntax, since many answers will contain C# samples and not VB.NET ones. – Conrad Frix Apr 19 '11 at 14:24

2 Answers2

4

Wikipedia has a good comparison of the two.

Personally, I chose to learn C# because I find the VB syntax too verbose, and the wages were higher. I think there's sometimes an (unjustified?) stigma attached to VB.NET that it's a 'lesser' language, and that can sometimes be reflected in the attitudes of employers and subsequently the remuneration on offer.

At the end of the day though, the output you get from either language is the same.

Town
  • 14,706
  • 3
  • 48
  • 72
2

I'd advise you to program in the language you are comfortable with. There are minor differences in the languages (C# has some syntactic features that vb.net doesn't and vice versa), but eventually, they compile to the same ILCode and thus perform the same.

Femaref
  • 60,705
  • 7
  • 138
  • 176
  • 6
    Meh, I disagree. I came from a VB6 background. VB6 does not encourage good OO thoughts; I say: start clean - switch language. – Marc Gravell Apr 18 '11 at 21:25
  • Depends entirely on the experience of the person, so I wouldn't say it that harsh. I switched from php to c#, the former doesn't encourage OO either, and I turned out just fine, even though the syntax is similar. – Femaref Apr 18 '11 at 21:27
  • The continued association between VB6 and VB.net are horrendous. I have a background in both and they are completely different. The only similarities are somethings with the syntax. – Freesnöw Apr 18 '11 at 21:27