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. Why VB.Net blah blah... [modified]

Why VB.Net blah blah... [modified]

Scheduled Pinned Locked Moved The Lounge
csharp
70 Posts 44 Posters 43 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.
  • realJSOPR realJSOP

    Rama Krishna Vavilala wrote:

    For manual code, yes!

    For ANY code - yes. It's like using goto. Just because you *can* use it doesn't mean you *should*.

    .45 ACP - because shooting twice is just silly
    -----
    "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
    -----
    "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

    S Offline
    S Offline
    Simon_Whale
    wrote on last edited by
    #21

    John Simmons / outlaw programmer wrote:

    Just because you *can* use it doesn't mean you *should*.

    Best advice ever!

    As barmey as a sack of badgers Dude, if I knew what I was doing in life, I'd be rich, retired, dating a supermodel and laughing at the rest of you from the sidelines.

    1 Reply Last reply
    0
    • realJSOPR realJSOP

      I wasn't ready for this:

      Dim [step] as String

      I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

      .45 ACP - because shooting twice is just silly
      -----
      "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
      -----
      "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

      modified on Thursday, November 18, 2010 9:55 AM

      D Offline
      D Offline
      Dr Walt Fair PE
      wrote on last edited by
      #22

      Ahhh yes, cricket. Such things happen so you can learn humility. OTOH, at least you're not using FORTRAN or COBOL! BTW, I'm a slow learner.

      CQ de W5ALT

      Walt Fair, Jr., P. E. Comport Computing Specializing in Technical Engineering Software

      1 Reply Last reply
      0
      • D Dalek Dave

        John Simmons / outlaw programmer wrote:

        VB is a scurge on mankind

        Scourge, surely?

        ------------------------------------ I will never again mention that I was the poster of the One Millionth Lounge Post, nor that it was complete drivel. Dalek Dave CCC League Table Link CCC Link[^]

        G Offline
        G Offline
        Gary Wheeler
        wrote on last edited by
        #23

        You do realize that correcting John's spelling when he's pissed about something is about as safe as telling Chuck Norris to keep off the grass?

        Software Zen: delete this;

        D 1 Reply Last reply
        0
        • N Nemanja Trifunovic

          Potato, pothato:

          string @int = "Hi, John";

          utf8-cpp

          G Offline
          G Offline
          Gary Wheeler
          wrote on last edited by
          #24

          There is no conceivable reason whatsoever to do such a thing. If I found my minion pulling a trick like that, I would leave his head mounted on a pike outside the castle wall as a warning to the applicants to assume his position.

          Software Zen: delete this;

          realJSOPR S 2 Replies Last reply
          0
          • realJSOPR realJSOP

            I wasn't ready for this:

            Dim [step] as String

            I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

            .45 ACP - because shooting twice is just silly
            -----
            "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
            -----
            "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

            modified on Thursday, November 18, 2010 9:55 AM

            L Offline
            L Offline
            Luc Pattyn
            wrote on last edited by
            #25

            almost any 3, 4 or 5-letter combination is a keyword in VB. Without this feature you would be restricted to 1- and 2-letter identifiers, and really long ones. :)

            Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles] Nil Volentibus Arduum

            Please use <PRE> tags for code snippets, they preserve indentation, and improve readability.

            1 Reply Last reply
            0
            • G Gary Wheeler

              There is no conceivable reason whatsoever to do such a thing. If I found my minion pulling a trick like that, I would leave his head mounted on a pike outside the castle wall as a warning to the applicants to assume his position.

              Software Zen: delete this;

              realJSOPR Offline
              realJSOPR Offline
              realJSOP
              wrote on last edited by
              #26

              I have a strong feeling that you and I are so much alike that we could almost finish each other's sentences.

              .45 ACP - because shooting twice is just silly
              -----
              "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
              -----
              "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

              1 Reply Last reply
              0
              • realJSOPR realJSOP

                I wasn't ready for this:

                Dim [step] as String

                I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

                .45 ACP - because shooting twice is just silly
                -----
                "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                -----
                "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                modified on Thursday, November 18, 2010 9:55 AM

                Steve EcholsS Offline
                Steve EcholsS Offline
                Steve Echols
                wrote on last edited by
                #27

                I also have to port stuff from C# to VB ( :( ): Public Enum Status Success Warning [Error] End Enum Without the [], I would have to name Error something else (Fubar comes to mind), and change every piece of code that uses it.


                - S 50 cups of coffee and you know it's on! Code, follow, or get out of the way.

                • S
                  50 cups of coffee and you know it's on!
                  Code, follow, or get out of the way.
                1 Reply Last reply
                0
                • G Gary Wheeler

                  You do realize that correcting John's spelling when he's pissed about something is about as safe as telling Chuck Norris to keep off the grass?

                  Software Zen: delete this;

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

                  Gary Wheeler wrote:

                  You do realize that correcting John's spelling when he's pissed about something is about as safe as telling Chuck Norris to keep off the grass?

                  Actually it's less safe. You can do the latter safely if you word it right, just ask him to one up Jesus by walking on air. :laugh:

                  3x12=36 2x12=24 1x12=12 0x12=18

                  1 Reply Last reply
                  0
                  • realJSOPR realJSOP

                    I wasn't ready for this:

                    Dim [step] as String

                    I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

                    .45 ACP - because shooting twice is just silly
                    -----
                    "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                    -----
                    "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                    modified on Thursday, November 18, 2010 9:55 AM

                    M Offline
                    M Offline
                    Member 96
                    wrote on last edited by
                    #29

                    You sir are living in your own personal hell, my condolences. :)


                    “If you want to build a ship, don't drum up people together to collect wood and don't assign them tasks and work, but rather teach them to long for the endless immensity of the sea” - Antoine de Saint-Exupery

                    1 Reply Last reply
                    0
                    • realJSOPR realJSOP

                      I'm using a web site that converts. For the most part, it does an okay job, but Linq statements tend to freak it out. I have a LOT of linq statements. I hate pretty much everything about VB, so this makes me hate my job. I updated my resume last night. I think my boss doesn't want to learn C#. I recognize that VB abnd C# are pretty much the same, but the differences are infuriating, and I simply don't like coding in it. NOTHING will change my outlook regarding VB. It has no redeeming features.

                      .45 ACP - because shooting twice is just silly
                      -----
                      "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                      -----
                      "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                      M Offline
                      M Offline
                      Mycroft Holmes
                      wrote on last edited by
                      #30

                      John Simmons / outlaw programmer wrote:

                      think my boss doesn't want to learn C#

                      That was the complaint I got from my boss when I moved the teams to c#. We still support the VB apps but at least the move stuck. I have too many years making a living with VB to bitch about it. Just another tool as far as I care.

                      Never underestimate the power of human stupidity RAH

                      1 Reply Last reply
                      0
                      • R Rama Krishna Vavilala

                        It's like saying that assembler should not use jump statements or certain constructs. When you are auto-generating code which is not supposed to be read by anyone (sort of like ASP.NET does) this feature works well. The neat thing is that codedom automatically takes care of this.

                        J Offline
                        J Offline
                        JimmyRopes
                        wrote on last edited by
                        #31

                        It is also the only way I know to pass the HttpAttribute "class" (@class=""), which happens to be a reserved word, to be able to use CSS on a custom control defined in a HttpHelper. :thumbsup:

                        1 Reply Last reply
                        0
                        • G Gary Wheeler

                          There is no conceivable reason whatsoever to do such a thing. If I found my minion pulling a trick like that, I would leave his head mounted on a pike outside the castle wall as a warning to the applicants to assume his position.

                          Software Zen: delete this;

                          S Offline
                          S Offline
                          S Senthil Kumar
                          wrote on last edited by
                          #32

                          Gary Wheeler wrote:

                          There is no conceivable reason whatsoever to do such a thing

                          I guess it's meant to be used mostly by automated tools generating source code. I've seen @object used as a variable/parameter name when the type is object, like so

                          public override void Equals(object @object)
                          { ... }

                          Regards Senthil _____________________________ My Home Page |My Blog | My Articles | My Flickr | WinMacro

                          G 1 Reply Last reply
                          0
                          • realJSOPR realJSOP

                            I'm using a web site that converts. For the most part, it does an okay job, but Linq statements tend to freak it out. I have a LOT of linq statements. I hate pretty much everything about VB, so this makes me hate my job. I updated my resume last night. I think my boss doesn't want to learn C#. I recognize that VB abnd C# are pretty much the same, but the differences are infuriating, and I simply don't like coding in it. NOTHING will change my outlook regarding VB. It has no redeeming features.

                            .45 ACP - because shooting twice is just silly
                            -----
                            "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                            -----
                            "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                            G Offline
                            G Offline
                            GDMFSOB
                            wrote on last edited by
                            #33

                            Download SharpDevelop its an open source C# IDE that has a built in C# to VB and vice versa converter works like a charm, I write in VB and an constanly too lazy to convert C# to VB manually, or you can get hold of .net reflector, you can reverse engineer the whole project into any .net lanugauge you want in one foul swoop. :)

                            D 1 Reply Last reply
                            0
                            • realJSOPR realJSOP

                              I wasn't ready for this:

                              Dim [step] as String

                              I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

                              .45 ACP - because shooting twice is just silly
                              -----
                              "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                              -----
                              "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                              modified on Thursday, November 18, 2010 9:55 AM

                              F Offline
                              F Offline
                              Fabio Franco
                              wrote on last edited by
                              #34

                              This is one of the most shocking and most stupid things I've ever heard. If I were you I would throw pretty much every argument I have and can google in order to make him change his mind. I can suggest you one (hope not to be flamed): VB programmers are VB programmers because they don't know or are incapable of programming in any other language. Converting the project to VB is a downgrade in quality and practices. It will stimulate bad programmers to join the project's team and it will repel good programmers and thus, decreasing the quality of the software and it's maintenance. And yes, VB is a scourge and I feel pretty ashamed to have started programming on it (VB 5).

                              R 1 Reply Last reply
                              0
                              • S S Senthil Kumar

                                Gary Wheeler wrote:

                                There is no conceivable reason whatsoever to do such a thing

                                I guess it's meant to be used mostly by automated tools generating source code. I've seen @object used as a variable/parameter name when the type is object, like so

                                public override void Equals(object @object)
                                { ... }

                                Regards Senthil _____________________________ My Home Page |My Blog | My Articles | My Flickr | WinMacro

                                G Offline
                                G Offline
                                Gary Wheeler
                                wrote on last edited by
                                #35

                                So what? The automated tool could just as easily generate a decorated name (__object__) that wasn't a reserved name in the language. I maintain that this is a stupid feature, one that inexperienced programmers will delight in, and the rest of us will have to clean up their shit.

                                Software Zen: delete this;

                                N 1 Reply Last reply
                                0
                                • realJSOPR realJSOP

                                  I wasn't ready for this:

                                  Dim [step] as String

                                  I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

                                  .45 ACP - because shooting twice is just silly
                                  -----
                                  "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                                  -----
                                  "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                                  modified on Thursday, November 18, 2010 9:55 AM

                                  R Offline
                                  R Offline
                                  rurouniRonin
                                  wrote on last edited by
                                  #36

                                  It's not pretty but that kinda thing does come in handy from time to time. Like in SQL when you would like to name things semantically - like calling a field [Option] because, well, it's an option. I agree it's not really the greatest feature but it does allow for a bit more flexibility and so long as the person coding knows what they're doing it's not a problem. It was also mentioned earlier that it's there for backwards compatibility so if in a later version of a language they want to add a new keyword then they can do so without running the risk of completely mangling older code. Smarter people than us have developed all these languages so there's pretty much always gonna be a good reason behind these things whether we like them or not ;) PS: When will they add inline if statements to VB? :(

                                  1 Reply Last reply
                                  0
                                  • F Fabio Franco

                                    This is one of the most shocking and most stupid things I've ever heard. If I were you I would throw pretty much every argument I have and can google in order to make him change his mind. I can suggest you one (hope not to be flamed): VB programmers are VB programmers because they don't know or are incapable of programming in any other language. Converting the project to VB is a downgrade in quality and practices. It will stimulate bad programmers to join the project's team and it will repel good programmers and thus, decreasing the quality of the software and it's maintenance. And yes, VB is a scourge and I feel pretty ashamed to have started programming on it (VB 5).

                                    R Offline
                                    R Offline
                                    rurouniRonin
                                    wrote on last edited by
                                    #37

                                    VB is designed to be human readable and easy to understand and it does the job just fine. The only bad VB programmers out there are programmers that are equally bad at programming in any other language - it's not the language that's at fault, it's the people using it poorly. Give a bad driver a bentley and he'll still crash it regardless of how awesome it is. Converting to VB just means a project will have slightly less OO control and capability. In most situations you don't need those extra goodies in any case. One day you will be saying exactly the same thing about C#. Back in the day people thought VB was awesome too. Languages suit personal tastes and styles and the task at hand. Like if I need to write a game I use C#, if I need to make a simple windows app I use VB. Give an example of why VB is terrible rather than just complaining about it and then give an example of why another language is so much greater :(

                                    F 1 Reply Last reply
                                    0
                                    • realJSOPR realJSOP

                                      I wasn't ready for this:

                                      Dim [step] as String

                                      I was shocked and appalled to find out that VB allows you to do this kind of thing - using reserved words as variable names... Not only freakin' amazing, but amazingly bad practice... And you guys should just go ahead and brace yoourselves - after coding our Silverlight project in C# since March (and that is between 90 and 95% completed), my boss had a fit and decided he wanted it converted to VB because that's what everything else in the shop is coded in (and he was the one that okayed C# to begin with). I am (and I think understandably so) quite upset/annoyed/pissed off about it. Expect to see more posts like this as I progress through the conversion. IMHO, VB is a scourge on mankind.

                                      .45 ACP - because shooting twice is just silly
                                      -----
                                      "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                                      -----
                                      "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                                      modified on Thursday, November 18, 2010 9:55 AM

                                      K Offline
                                      K Offline
                                      Kalyan_A
                                      wrote on last edited by
                                      #38

                                      not sure what the fuss is all about! its a feature supported by (almost) all the languages out there!!! with all due respect, looks like you are just frustrated for having to work in vb!!! ..peace... :rose: btw... yes i do develop in vb most of the time :)

                                      1 Reply Last reply
                                      0
                                      • realJSOPR realJSOP

                                        I'm using a web site that converts. For the most part, it does an okay job, but Linq statements tend to freak it out. I have a LOT of linq statements. I hate pretty much everything about VB, so this makes me hate my job. I updated my resume last night. I think my boss doesn't want to learn C#. I recognize that VB abnd C# are pretty much the same, but the differences are infuriating, and I simply don't like coding in it. NOTHING will change my outlook regarding VB. It has no redeeming features.

                                        .45 ACP - because shooting twice is just silly
                                        -----
                                        "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                                        -----
                                        "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                                        S Offline
                                        S Offline
                                        ScottM1
                                        wrote on last edited by
                                        #39

                                        I agree with GDMFSOB, SharpDevelop is an excellent converter.

                                        1 Reply Last reply
                                        0
                                        • R rurouniRonin

                                          VB is designed to be human readable and easy to understand and it does the job just fine. The only bad VB programmers out there are programmers that are equally bad at programming in any other language - it's not the language that's at fault, it's the people using it poorly. Give a bad driver a bentley and he'll still crash it regardless of how awesome it is. Converting to VB just means a project will have slightly less OO control and capability. In most situations you don't need those extra goodies in any case. One day you will be saying exactly the same thing about C#. Back in the day people thought VB was awesome too. Languages suit personal tastes and styles and the task at hand. Like if I need to write a game I use C#, if I need to make a simple windows app I use VB. Give an example of why VB is terrible rather than just complaining about it and then give an example of why another language is so much greater :(

                                          F Offline
                                          F Offline
                                          Fabio Franco
                                          wrote on last edited by
                                          #40

                                          John Simmons already posted in his original thread an example of how VB is terrible. There are many others like having to turn Option Stric On to forbid conversions that have loss of precision. This and many other goodies of VB are just a trap to attract bad practices. I myself had to do a lot of re-learning and training to get rid of terrible habits I aquired with VB. Yes, VB is easier to understand for new programmers, it's more readable to them (not to me of course). I agree with you that the language itself isn't enough to tell if someone is a good or a bad programmer. But I think most will agree with me that there are much more bad programmers in VB than there is in C# and that are much more great programmers in C# than there is in VB. The car analogy is also perfect for that. How many excelent drivers are in this group? Car equiped with: Automatic transmission, traction control, ABS brakes, auto traction compensation and on this: Car equiped with: Manual transmission, no traction control, Hardcore brakes, Do high speed turns on your on skill That's my point. Nothing against someone prefer VB, but I'd never do a VB based project if I owned a company. [Edit] My original post was a little offensive and it's not to be taken serious and personally. It does not mean it's a fact, it's just how I feel about it without having to put all arguments on the table.

                                          modified on Friday, November 19, 2010 6:53 AM

                                          R 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