Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. difference between C# and VB.Net except syntax Dinesh Says Thanx ....

difference between C# and VB.Net except syntax Dinesh Says Thanx ....

Scheduled Pinned Locked Moved The Lounge
csharpbusiness
68 Posts 36 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D DineshSharma

    can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

    S Offline
    S Offline
    Super Lloyd
    wrote on last edited by
    #2

    if you remove the syntax issue much is left out.... Anyway, here on CP are a few articles doing comparison: http://www.codeproject.com/dotnet/vbnet_c__difference.asp[^] http://www.codeproject.com/useritems/vbdefamation.asp[^] And I want to add VB is much more verbose, same code is about 10% bigger, because of longer keywordand syntax. This 10% more opportunity for bug! Althoug VS.NET autocompletion is good at getting rid of them...

    D V C K 4 Replies Last reply
    0
    • S Super Lloyd

      if you remove the syntax issue much is left out.... Anyway, here on CP are a few articles doing comparison: http://www.codeproject.com/dotnet/vbnet_c__difference.asp[^] http://www.codeproject.com/useritems/vbdefamation.asp[^] And I want to add VB is much more verbose, same code is about 10% bigger, because of longer keywordand syntax. This 10% more opportunity for bug! Althoug VS.NET autocompletion is good at getting rid of them...

      D Offline
      D Offline
      DineshSharma
      wrote on last edited by
      #3

      thanks for quick responce is there any big difference like i cant do in vb.net but able to do in c# or v/v Dinesh Sharma

      S N C 3 Replies Last reply
      0
      • D DineshSharma

        thanks for quick responce is there any big difference like i cant do in vb.net but able to do in c# or v/v Dinesh Sharma

        S Offline
        S Offline
        Super Lloyd
        wrote on last edited by
        #4

        I believe there is some problem with attribute in VB. Also if you got an API using byte, short, etc... (all number type beside int) it's kind of akward to use it in VB. It's still possible, but it's akward. Also I love the using(x) {} statment of C#, with automatic disposal. of course you could try {} finally { Dispose(); } in VB, but that's akward as well....

        P 1 Reply Last reply
        0
        • D DineshSharma

          thanks for quick responce is there any big difference like i cant do in vb.net but able to do in c# or v/v Dinesh Sharma

          N Offline
          N Offline
          nicko
          wrote on last edited by
          #5

          don't know about .Net v2.0, but with v1.1 you can only inherit from a single base class (which can in turn inherit from a single base class, and so on) - ie. doesn't support multiple inheritance :( thats the one big limitation with VB.Net that i know of - there are many smaller ones (but none that spring to mind right now). nicko

          S R 2 Replies Last reply
          0
          • N nicko

            don't know about .Net v2.0, but with v1.1 you can only inherit from a single base class (which can in turn inherit from a single base class, and so on) - ie. doesn't support multiple inheritance :( thats the one big limitation with VB.Net that i know of - there are many smaller ones (but none that spring to mind right now). nicko

            S Offline
            S Offline
            Shaun Wilde
            wrote on last edited by
            #6

            I think you'll find that in c# as well - it's .NET that constrains this not the language

            I'll be more enthusiastic about encouraging thinking outside the box when there's evidence of any thinking going on inside it. - pTerry
            www.many-monkeys.com

            1 Reply Last reply
            0
            • S Super Lloyd

              if you remove the syntax issue much is left out.... Anyway, here on CP are a few articles doing comparison: http://www.codeproject.com/dotnet/vbnet_c__difference.asp[^] http://www.codeproject.com/useritems/vbdefamation.asp[^] And I want to add VB is much more verbose, same code is about 10% bigger, because of longer keywordand syntax. This 10% more opportunity for bug! Althoug VS.NET autocompletion is good at getting rid of them...

              V Offline
              V Offline
              Vivek Rajan
              wrote on last edited by
              #7

              Super Lloyd wrote:

              And I want to add VB is much more verbose, same code is about 10% bigger, because of longer keywordand syntax. This 10% more opportunity for bug!

              More verbose does not necessarily mean more bugs.

              D 1 Reply Last reply
              0
              • D DineshSharma

                can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                C Offline
                C Offline
                Christian Graus
                wrote on last edited by
                #8

                There is a degree to which you're asking about the difference between Roman Catholic and Orthodox here - a degree to which the two sides will say 'the other will burn in HELL'. The truth is, they generate the same IL, so in the hands of a good programmer, there's no difference. However, VB contains a lot of stuff that Microsoft wanted to kill, and the VB community would not let them, C# is by far a better designed language, IMO. I also personally hate VB syntax, it gives me a gut ache. Some people feel the same about C#, I'm told. So, if you have a choice between a skilled VB team and a skilled C# team, and you don't care about the stigma of VB, toss a coin. Otherwise, if you're going to learn a language, I'd say toss a coin again. If you have a choice between a C# team and a team who went to VB.NET from VB6, I'd take the C# team, every time. Christian Graus - Microsoft MVP - C++

                R I D K 4 Replies Last reply
                0
                • N nicko

                  don't know about .Net v2.0, but with v1.1 you can only inherit from a single base class (which can in turn inherit from a single base class, and so on) - ie. doesn't support multiple inheritance :( thats the one big limitation with VB.Net that i know of - there are many smaller ones (but none that spring to mind right now). nicko

                  R Offline
                  R Offline
                  Ryan Binns
                  wrote on last edited by
                  #9

                  nicko wrote:

                  don't know about .Net v2.0, but with v1.1 you can only inherit from a single base class (which can in turn inherit from a single base class, and so on) - ie. doesn't support multiple inheritance

                  That's a feature of .NET. You can only inherit from one base class, but you can implement multiple interfaces. It's the same with C#.

                  Ryan

                  "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"

                  J 1 Reply Last reply
                  0
                  • D DineshSharma

                    thanks for quick responce is there any big difference like i cant do in vb.net but able to do in c# or v/v Dinesh Sharma

                    C Offline
                    C Offline
                    Christian Graus
                    wrote on last edited by
                    #10

                    VB has nicer syntax for events, IMO, but most of what VB offers that C# doesn't is just syntactic sugar. However, C# has always been ahead of the curve on features, until 2.0, VB did not offer operator overloading, for example. Christian Graus - Microsoft MVP - C++

                    1 Reply Last reply
                    0
                    • S Super Lloyd

                      if you remove the syntax issue much is left out.... Anyway, here on CP are a few articles doing comparison: http://www.codeproject.com/dotnet/vbnet_c__difference.asp[^] http://www.codeproject.com/useritems/vbdefamation.asp[^] And I want to add VB is much more verbose, same code is about 10% bigger, because of longer keywordand syntax. This 10% more opportunity for bug! Althoug VS.NET autocompletion is good at getting rid of them...

                      C Offline
                      C Offline
                      Christian Graus
                      wrote on last edited by
                      #11

                      Super Lloyd wrote:

                      This 10% more opportunity for bug!

                      LOL - VB is a lot more than 10 % bigger, but I don't see that as causing bugs, the syntax is just more verbose. I hate it for that reason, but I wouldn't claim it causes bugs. Christian Graus - Microsoft MVP - C++

                      1 Reply Last reply
                      0
                      • D DineshSharma

                        can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                        H Offline
                        H Offline
                        HimaBindu Vejella
                        wrote on last edited by
                        #12

                        MS developed everything FCls and APIs System level in C# Hence C# is MS preferred language Even I do prefer CSha.. "Aim to go where U have never been B4 and Strive to achieve it" http://groups.yahoo.com/subscribe/dotnetforfreshers http://himabinduvejella.blogspot.com

                        1 Reply Last reply
                        0
                        • D DineshSharma

                          can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                          M Offline
                          M Offline
                          Marc Clifton
                          wrote on last edited by
                          #13

                          DineshSharma wrote:

                          why should I use the C# for my business application development and why vb.net

                          Those who know the answer use C#. Those who have to ask use VB. Marc Pensieve Some people believe what the bible says. Literally. At least [with Wikipedia] you have the chance to correct the wiki -- Jörgen Sigvardsson -- modified at 6:28 Monday 15th May, 2006

                          N I 2 Replies Last reply
                          0
                          • D DineshSharma

                            can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                            P Offline
                            P Offline
                            Phil J Pearson
                            wrote on last edited by
                            #14

                            C# is a language; VB is a pidgin! :-D

                            K 1 Reply Last reply
                            0
                            • D DineshSharma

                              can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                              M Offline
                              M Offline
                              Mark II
                              wrote on last edited by
                              #15

                              Some less technical differences: 1) Culture. IMHO, VB.Net and C# developers appear think differently about a probem. C# developers like to do things the new way. VB.Net developers tend to stick with what they know. 2) Perception. In some circles, it seems that C# developers are seen as more professional than VB.Net programmers. 3) RSI. VB.Net developers do more typing than C# developers. E.g. "C#" is just 2 characters, "VB.Net" is 6. 4) Comments. C# developers can put comments in the middle of lines of code, e.g. parameter lists. VB.Net programmers have to keep their comments at the ends of lines. 5) Internet searches. VB.Net programmers tend to turn up a lot of articles on classic VB. I guess that C# programmmers are more likely to find Java articles. 6) Example code. Broadly speaking, articles on very techincal stuff seem to have C# example code. The easier to understand tutorials seem to be accompanied by VB.Net code. The truth is that if you know one of these languages, the other is exactly the same but... er... different.

                              E 1 Reply Last reply
                              0
                              • D DineshSharma

                                can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                                D Offline
                                D Offline
                                Dan Neely
                                wrote on last edited by
                                #16

                                There're very few differences. The only two I can think of off the top of my head is the C# allows the use of unsafe code (real pointers), while VB.net allows optional parameters (potentially useful for com interop).

                                1 Reply Last reply
                                0
                                • M Marc Clifton

                                  DineshSharma wrote:

                                  why should I use the C# for my business application development and why vb.net

                                  Those who know the answer use C#. Those who have to ask use VB. Marc Pensieve Some people believe what the bible says. Literally. At least [with Wikipedia] you have the chance to correct the wiki -- Jörgen Sigvardsson -- modified at 6:28 Monday 15th May, 2006

                                  N Offline
                                  N Offline
                                  NeverHeardOfMe
                                  wrote on last edited by
                                  #17

                                  A difference between the C "family" and the Visual Basic "family" used to be that the former was a better choice if application performace was your goal, and the latter if productivity (ie producing a working programme quickly) was more important. With the introduction of .NET this difference though perhaps still there to some extent is less the case - and one has to wonder if that is a good thing...

                                  Marc Clifton wrote:

                                  Those who know the answer use C#. Those who have to ask use VB.

                                  Code-snobs choose C because they think it makes them look smarter. Smart people choose VB because it's easier. :) cheers P

                                  M D C 3 Replies Last reply
                                  0
                                  • S Super Lloyd

                                    I believe there is some problem with attribute in VB. Also if you got an API using byte, short, etc... (all number type beside int) it's kind of akward to use it in VB. It's still possible, but it's akward. Also I love the using(x) {} statment of C#, with automatic disposal. of course you could try {} finally { Dispose(); } in VB, but that's akward as well....

                                    P Offline
                                    P Offline
                                    Pascal Ganaye
                                    wrote on last edited by
                                    #18

                                    Since the dotnet framework 2.0, Vb.net has the using statement. As far as I know it works the same as C#

                                    1 Reply Last reply
                                    0
                                    • D DineshSharma

                                      can anybody confirm me theat whats the basic difference between c# and VB.Net. why should I use the C# for my business application development and why vb.net Dear all ...Thanks a lot for your suggestion and a lot of responces.......Thanx:laugh: Dinesh Sharma -- modified at 8:01 Tuesday 16th May, 2006

                                      P Offline
                                      P Offline
                                      Pascal Ganaye
                                      wrote on last edited by
                                      #19

                                      I don't think anyone mentioned that VB is not case sensitive. The editor is more intelligent I believe. It compiles in the background and underlines errors and also remove the errors without having to recompile. As far as I am concerned these two points makes VB a better rapid development system.

                                      1 Reply Last reply
                                      0
                                      • N NeverHeardOfMe

                                        A difference between the C "family" and the Visual Basic "family" used to be that the former was a better choice if application performace was your goal, and the latter if productivity (ie producing a working programme quickly) was more important. With the introduction of .NET this difference though perhaps still there to some extent is less the case - and one has to wonder if that is a good thing...

                                        Marc Clifton wrote:

                                        Those who know the answer use C#. Those who have to ask use VB.

                                        Code-snobs choose C because they think it makes them look smarter. Smart people choose VB because it's easier. :) cheers P

                                        M Offline
                                        M Offline
                                        Marc Clifton
                                        wrote on last edited by
                                        #20

                                        Phil Uribe wrote:

                                        Smart people choose VB because it's easier.

                                        Why? What's easier about it? (Remember, we're talking the language here, not the tools/designers). Marc Pensieve Some people believe what the bible says. Literally. At least [with Wikipedia] you have the chance to correct the wiki -- Jörgen Sigvardsson

                                        N 1 Reply Last reply
                                        0
                                        • M Mark II

                                          Some less technical differences: 1) Culture. IMHO, VB.Net and C# developers appear think differently about a probem. C# developers like to do things the new way. VB.Net developers tend to stick with what they know. 2) Perception. In some circles, it seems that C# developers are seen as more professional than VB.Net programmers. 3) RSI. VB.Net developers do more typing than C# developers. E.g. "C#" is just 2 characters, "VB.Net" is 6. 4) Comments. C# developers can put comments in the middle of lines of code, e.g. parameter lists. VB.Net programmers have to keep their comments at the ends of lines. 5) Internet searches. VB.Net programmers tend to turn up a lot of articles on classic VB. I guess that C# programmmers are more likely to find Java articles. 6) Example code. Broadly speaking, articles on very techincal stuff seem to have C# example code. The easier to understand tutorials seem to be accompanied by VB.Net code. The truth is that if you know one of these languages, the other is exactly the same but... er... different.

                                          E Offline
                                          E Offline
                                          Eric Dahlvang
                                          wrote on last edited by
                                          #21

                                          Mark II wrote:

                                          VB.Net developers do more typing than C# developers. E.g. "C#" is just 2 characters, "VB.Net" is 6.

                                          :laugh: ---------- There go my people. I must find out where they are going so I can lead them. - Alexander Ledru-Rollin

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups