Visual Basic - I'm in Hell [modified]
-
John Simmons / outlaw programmer wrote:
HELLO! IT'S 2009! Get a real job, loser, and learn C#.
I seem to recall a lot of C++ folks dissing C# when it was new. I think they actually compared it to VB due to the warm and fuzzy front end and lack of pointers. Times have certainly changed...
I still see people who think that C# is faster than VB. One guy in a forum actually explained it was because C# has less text in the same code, so the computer can read it faster....
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
-
In VB6, arrays were 0 based. In fact you need to got back to vb3 [AFAIR] for the 1 based arrays by default. VB6 collections where 1 absed, but that's another story.
Panic, Chaos, Destruction. My work here is done.
If you go back even farther (Turbo?) Pascal would let you define an array with an arbitrary range. If you wanted legal indexes to be -3 to +21 you could define it that way and it'd do the offset math for you. :cool: OTOH my teacher never explained that we should start at 0 to avoid bad habits because all normal languages did so and that it would result in faster code. :doh:
3x12=36 2x12=24 1x12=12 0x12=18
-
If you go back even farther (Turbo?) Pascal would let you define an array with an arbitrary range. If you wanted legal indexes to be -3 to +21 you could define it that way and it'd do the offset math for you. :cool: OTOH my teacher never explained that we should start at 0 to avoid bad habits because all normal languages did so and that it would result in faster code. :doh:
3x12=36 2x12=24 1x12=12 0x12=18
[bond voice=Q] Pay attention Neely! [bond=off] I said default!, this is valid:
Dim StringArray(-7 To 42) As String
Panic, Chaos, Destruction. My work here is done.
-
Welcome back, Corinna, haven't seen you in a while. Who had the pleasure of your lovely company, and how are you doing? :)
Cheers, Vikram. (Cracked not one CCC, but two!)
Back? I've been reading here many times, especially the JOTDs. I just didn't know smart things to post here. You know, I don't babble when there's nothing to say - I simply shut up. :rolleyes:
This statement is false.
-
I still see people who think that C# is faster than VB. One guy in a forum actually explained it was because C# has less text in the same code, so the computer can read it faster....
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
Oh yes, and comments slow down the program, because the computer has jump around them...
This statement is false.
-
Back? I've been reading here many times, especially the JOTDs. I just didn't know smart things to post here. You know, I don't babble when there's nothing to say - I simply shut up. :rolleyes:
This statement is false.
Babbling is much more fun.
Panic, Chaos, Destruction. My work here is done.
-
John Simmons / outlaw programmer wrote:
I hope I don't lose my Platinum Member status as a result of this job...
Some of us in the Platinum members' lounge were discussing this, John. Will let you know what we decide on this :rolleyes:
Regards, Nish
Nish’s thoughts on MFC, C++/CLI and .NET (my blog)
My latest book : C++/CLI in Action / Amazon.com linkDon't worry! I'm sure the more VB he has to do at work the more C# he'll need at home.
This statement is false.
-
Oh yes, and comments slow down the program, because the computer has jump around them...
This statement is false.
No, it has to READ them, so it knows what's about to happen.....
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
-
Yep. Agreed. I've worked with VB6. It's true that it encourages bad pratices. But, if you consider youselves to be a good/great programmer, you are bound to avoid them (like the use of variants X|). IF used properly, VB.NET code will generate the same MSIL that its C# counterpart will generate. In short, this is a never ending discussion. If you consider youself a programmer, you should not be bound to one single language. EDIT: I too am a C# guy, but I have learned early on NOT to hate any technology (I know, some of you'll say VB is not technology), however old school it is; and that helps, a lot :-D EDIT2: I see a lot of VB haters over here, so I'll stop now, before my existence gets endangered.
Currently Reading: Eclipse by Stephenie Meyer Next in Queue: Breaking Dawn by Stephenie Meyer - Kirtan
modified on Tuesday, November 24, 2009 8:12 AM
I've noted that if you present a good argument, with logic and passion combined, you won't get many downvotes. Even if you like VB. While most of the people like X language and enjoy bashing Y language, they won't be jerks about it to the people that like Y language. I'm a newb programmer with mostly the 3 flavors of C under my belt and some VB once upon a time. Playing with VB gave me headaches. But I am not going to tell the people they suck because they got it. Well, okay I might.
-
I am about to start my first day at a new job doing VB.Net (I think I just threw up a little in my mouth, and I didn't even say it out loud). How do you guys work with this without going absolutely insane? 0) "Dim" - what you must be if you actually *like* VB 1) Specifying the type AFTER the variable name - the order of the universe should not be changed 2) Pointless sytax - "as", "of", "is", "isnot", "then", "end" - why did they omit the really useful ones, like "whetherornot", "notquite", "absenceoflogic", and "barf"? 3) If there's a "Dim", why isn't there a "bright" and "off"? 4) Why is there a solid line at the end of a source file? When it stops scrolling, I must be at the end of the file - I don't need a line to show that I am. 5) Explicit, strict and infer - three different ways to make your code as reliable as soggy bread. 6) Why? Just WHY? I question my ability to survive in this kind of environment. I asked my wife to hid all of my pistols so I don't feel compelled to shoot myself... The IDE just shut down with this message:
Visual Studio is busy. We're trying to figure out where we went wrong. Seriously, we didn't think this Visual Basic thing would last more than a couple of months, yet here you are trying to make sense of something that makes none. HELLO! IT'S 2009! Get a real job, loser, and learn C#.
I hope I don't lose my Platinum Member status as a result of this job... I will NOT be posting VB articles..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, 2001modified on Tuesday, November 24, 2009 7:31 AM
Am I the only one whose going to stick up for this language? I mean, it's only a syntax at the end of the day. True, C# is more satisfying to work with, but there's not that much more in it that you can't do in VB. John, I think you'll get used to the syntax pretty quickly & soon wonder what all the fuss was about... Just spare a thought for all the poor sods out there who are stuck with VB6 X|
"An eye for an eye only ends up making the whole world blind"
-
In VB6, arrays were 0 based. In fact you need to got back to vb3 [AFAIR] for the 1 based arrays by default. VB6 collections where 1 absed, but that's another story.
Panic, Chaos, Destruction. My work here is done.
-
I've noted that if you present a good argument, with logic and passion combined, you won't get many downvotes. Even if you like VB. While most of the people like X language and enjoy bashing Y language, they won't be jerks about it to the people that like Y language. I'm a newb programmer with mostly the 3 flavors of C under my belt and some VB once upon a time. Playing with VB gave me headaches. But I am not going to tell the people they suck because they got it. Well, okay I might.
Thanks for the votes. I was just expressing my views, plainly. Its just that I didn't expect experienced programmers like John or Christian expressing their views about a langauge like this :rolleyes:
Currently Reading: Eclipse by Stephenie Meyer Next in Queue: Breaking Dawn by Stephenie Meyer - Kirtan
-
Am I the only one whose going to stick up for this language? I mean, it's only a syntax at the end of the day. True, C# is more satisfying to work with, but there's not that much more in it that you can't do in VB. John, I think you'll get used to the syntax pretty quickly & soon wonder what all the fuss was about... Just spare a thought for all the poor sods out there who are stuck with VB6 X|
"An eye for an eye only ends up making the whole world blind"
-
Am I the only one whose going to stick up for this language? I mean, it's only a syntax at the end of the day. True, C# is more satisfying to work with, but there's not that much more in it that you can't do in VB. John, I think you'll get used to the syntax pretty quickly & soon wonder what all the fuss was about... Just spare a thought for all the poor sods out there who are stuck with VB6 X|
"An eye for an eye only ends up making the whole world blind"
I don't dislike VB, I dislike some of the dolts using it; but not the language.
Panic, Chaos, Destruction. My work here is done.
-
No, it has to READ them, so it knows what's about to happen.....
Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
So, the people who write these comments are obviously better at writing comments than my team.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith
As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
-
Am I the only one whose going to stick up for this language? I mean, it's only a syntax at the end of the day. True, C# is more satisfying to work with, but there's not that much more in it that you can't do in VB. John, I think you'll get used to the syntax pretty quickly & soon wonder what all the fuss was about... Just spare a thought for all the poor sods out there who are stuck with VB6 X|
"An eye for an eye only ends up making the whole world blind"
Rob Smiley wrote:
you'll get used to the syntax pretty quickly & soon wonder what all the fuss was about...
I've been doing Delphi (simillar with it's begin/end/etc. and definitions) for about a year now, having come from C#, and while I am used to it, it still feels completely backwards and irritating.
He who makes a beast out of himself gets rid of the pain of being a man.
-
Thanks for the votes. I was just expressing my views, plainly. Its just that I didn't expect experienced programmers like John or Christian expressing their views about a langauge like this :rolleyes:
Currently Reading: Eclipse by Stephenie Meyer Next in Queue: Breaking Dawn by Stephenie Meyer - Kirtan
I'm not the one that gave you that vote. :-D You have another person that agrees with you. I see a lot of VB bashing but it usually is well founded or in jest because VB is like that kid that ate paste in grade school. You knew he would be the one to die in a horrible accident like being run over by a garbage truck backing up but you still couldn't hold much animosity. You just were frustrated with what could have been something much greater. Side note: I know someone that did, in fact, die this way and we all knew he would die in a comical yet utterly tragic accident.
-
I'm not the one that gave you that vote. :-D You have another person that agrees with you. I see a lot of VB bashing but it usually is well founded or in jest because VB is like that kid that ate paste in grade school. You knew he would be the one to die in a horrible accident like being run over by a garbage truck backing up but you still couldn't hold much animosity. You just were frustrated with what could have been something much greater. Side note: I know someone that did, in fact, die this way and we all knew he would die in a comical yet utterly tragic accident.
ragnaroknrol wrote:
I know someone that did, in fact, die this way and we all knew he would die in a comical yet utterly tragic accident.
Details please?
------------------------------------ In science, 'fact' can only mean 'confirmed to such a degree that it would be perverse to withhold provisional assent.' I suppose that apples might start to rise tomorrow, but the possibility does not merit equal time in physics classrooms. Stephen J Gould
-
I am about to start my first day at a new job doing VB.Net (I think I just threw up a little in my mouth, and I didn't even say it out loud). How do you guys work with this without going absolutely insane? 0) "Dim" - what you must be if you actually *like* VB 1) Specifying the type AFTER the variable name - the order of the universe should not be changed 2) Pointless sytax - "as", "of", "is", "isnot", "then", "end" - why did they omit the really useful ones, like "whetherornot", "notquite", "absenceoflogic", and "barf"? 3) If there's a "Dim", why isn't there a "bright" and "off"? 4) Why is there a solid line at the end of a source file? When it stops scrolling, I must be at the end of the file - I don't need a line to show that I am. 5) Explicit, strict and infer - three different ways to make your code as reliable as soggy bread. 6) Why? Just WHY? I question my ability to survive in this kind of environment. I asked my wife to hid all of my pistols so I don't feel compelled to shoot myself... The IDE just shut down with this message:
Visual Studio is busy. We're trying to figure out where we went wrong. Seriously, we didn't think this Visual Basic thing would last more than a couple of months, yet here you are trying to make sense of something that makes none. HELLO! IT'S 2009! Get a real job, loser, and learn C#.
I hope I don't lose my Platinum Member status as a result of this job... I will NOT be posting VB articles..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, 2001modified on Tuesday, November 24, 2009 7:31 AM
John Simmons / outlaw programmer wrote:
- Specifying the type AFTER the variable name - the order of the universe should not be changed
Having the type in front of the variable name is stupid. It leads to problems such as http://blogs.msdn.com/ericlippert/archive/2009/08/17/arrays-of-arrays.aspx[^]. It leads to even worse syntax in C (think function pointers). Moreover, it doesn't mix syntactically with lambdas - there's just no place in front where you could stick the return type. C++0x had to introduce the ability to specify the return type after the parameter list to solve this and other problems.
auto function(int a) -> int;
You can't beat the clarity of: VAR a : ARRAY[1..3] OF POINTER TO ARRAY[1..10, 1..10] OF INTEGER; Pascal/Delphi are somewhat less readable (but more concise) when it comes to pointers, but the general idea is the same: types should always be read left to right in a natural way. Of course, if you do this, you want the type to be on the right of variable name in a declaration, otherwise it just looks weird. I mean, say we had: [,][]int a; // huh?
-
I am about to start my first day at a new job doing VB.Net (I think I just threw up a little in my mouth, and I didn't even say it out loud). How do you guys work with this without going absolutely insane? 0) "Dim" - what you must be if you actually *like* VB 1) Specifying the type AFTER the variable name - the order of the universe should not be changed 2) Pointless sytax - "as", "of", "is", "isnot", "then", "end" - why did they omit the really useful ones, like "whetherornot", "notquite", "absenceoflogic", and "barf"? 3) If there's a "Dim", why isn't there a "bright" and "off"? 4) Why is there a solid line at the end of a source file? When it stops scrolling, I must be at the end of the file - I don't need a line to show that I am. 5) Explicit, strict and infer - three different ways to make your code as reliable as soggy bread. 6) Why? Just WHY? I question my ability to survive in this kind of environment. I asked my wife to hid all of my pistols so I don't feel compelled to shoot myself... The IDE just shut down with this message:
Visual Studio is busy. We're trying to figure out where we went wrong. Seriously, we didn't think this Visual Basic thing would last more than a couple of months, yet here you are trying to make sense of something that makes none. HELLO! IT'S 2009! Get a real job, loser, and learn C#.
I hope I don't lose my Platinum Member status as a result of this job... I will NOT be posting VB articles..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, 2001modified on Tuesday, November 24, 2009 7:31 AM
Well, when you cannot take it any longer, we are hiring C++/SQL/HTML skilled people in the Chicago area. Drop me a line right before your head explodes X|
onwards and upwards...