10 Reasons Why Visual Basic is Better Than C#
-
I have to agree with a lot of the issues with C#. The Switch statement is superior, and I also have to agree that good software eliminates Case/Switch statements. However, there is a lot more power in VB version and wish that the C# team would update the Case statement. I also disagree with maintaining the requirement for the break statement. There is no reason to keep it, and it should be eliminated. C# no longer has to deal with expectations of C community. Also, I like the fact that I do not have to worry about case sensitivity in Visual Basic. However I think that this can be resolved in the environment by being able to set a flag to allow the environment to fix case problems. C# does not preclude this since the environment could fix it, and maybe it should. I also like that there is case sensitivity since I can use a variable for a class or property and differentiate it by using low case. In fact the environment (may be fairly easy to implement with Roslyn) can enforce a bunch of naming rules. Of course a few issues are easily fixed by adding extension methods. Yes I think that C# should support them, but it is not really a language issues, it is more of an implementation issue. Yes there are some things like && that are implementation issues, but having the & function also can sometimes be useful. And it is standard with C, Java, etc. Next I will hear the guy asking to replace “+” with “add”. Yes C# could have used the other symbols (caret and reverse caret), but at least they are standard symbols (ever seen APL) I hate the Dim in VB because it no longer is a dimension. Maybe if VB used Def or define instead I might agree. As far as the “;” is concerned, I think that the “_” was worse. The situation has improved, but is it really better? I do agree that sometimes, especially with enumeration, it should not be necessary to specify the entire path. Would be good is C# fixed this. Anyway, VB does not follow other languages as well as C#. C# follows standards created by C and C++.
Clifford Nelson wrote:
I also disagree with maintaining the requirement for the break statement. There is no reason to keep it, and it should be eliminated.
Hear hear!
Clifford Nelson wrote:
I think that the “_” was worse
Indeed.
Clifford Nelson wrote:
with enumeration, it should not be necessary to specify the entire path
I disagree; I very much prefer to see which enumeration a value belongs to -- particularly when code is posted in a question here.
-
Here[^] Now, where was that bulletproof vest? <Takes cover under a fireproof blanket> A bulletproof vest can take at least one 45ACP, right?
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
That, dear sir, conforms to lunacy. Seriously? Case sensitivity alone is reason to ditch C#? Ever hear of intellisense? As the other intelligible 'academic' above me pointed out, learning to use your IDE is crucial if you want to be a developer. Personally, I would much rather have an academic write my code than a kindergartner. They tend to think better. Good luck with your VB endeavors. I shall see you when you're done debugging. I shall now end my thoughts of anger with this period.
-
I love VB as a language. I also completely agree with the IntelliSense thing... C# IntelliSense is a disaster if you're used to VB. For example: Typing VB: Dim ex As ExcepR... Oops, backspace, tab and it's there. Typing C#: ExcepR... Oops, backspace, no IntelliSense window pops up, either four times backspace or Shift + Home + Delete/Backspace. If you're lucky you don't have to switch to a new line to get IntelliSense support again! This becomes really very frustrating when you got code like obj.Property1.Property2.Property3... However, one reason NOT to use VB...
Form1.Text = "What the? Since when is Text a Shared/static Property!?"
The answer to that question is: Since VB1. And it's still there for 'backwards compatibility' (the compiler does create an instance though) :) So much for Object Orientism. Another one is the default of Option Strict Off. I've seen 'modern' VB code that used the horrible Form1.Text thing and Option Strict Off... You'll never see that in C#. Of course bad code can be written in both languages and with that philosophy in mind I don't really care which language I write. I just slightly prefer VB for IntelliSense and Event Handling in WinForms (that guy is so right about that!) :)
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
}Quote:
Typing VB: Dim ex As ExcepR... Oops, backspace, tab and it's there. Typing C#: ExcepR... Oops, backspace, no IntelliSense window pops up, either four times backspace or Shift + Home + Delete/Backspace.
Try pressing backspace, then CTRL+SPACE.
-
Here[^] Now, where was that bulletproof vest? <Takes cover under a fireproof blanket> A bulletproof vest can take at least one 45ACP, right?
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
-
VB is a bit more forgiving and easier to code in than C, C++ or C#. The High Priests of Coding want to keep the Unwashed Masses away from their profession. There is nothing else to the snobbery of the C group toward the VB group.
There is still a large group of programmers using VB6 because VB.Net is precieved to have a much steeper learning curve. I have to agree that VB is not much different than C#, and the effective differences have been narrowed over the last few releases since there has been a lot of effort equalizing the products. There is however, a difference between C# and VB developers in that there tends to be a higher quality of programmers in C#, whether that is because developers in C# tend to come from C++ or some other C based OO language or there are higher expectations, or something else I do not know. I worked in VB6 prior to moving to C# and .NET, and I know about the attitude towards VB developers. I also know that there are some highly respected and significant supporters of VB.
-
IntelliSense is not a part of either language.
True, but it's my most used feature of my most used IDE. And this feature works for VB, but doesn't (or at least not good enough to my taste) for C# :)
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
} -
Quote:
Typing VB: Dim ex As ExcepR... Oops, backspace, tab and it's there. Typing C#: ExcepR... Oops, backspace, no IntelliSense window pops up, either four times backspace or Shift + Home + Delete/Backspace.
Try pressing backspace, then CTRL+SPACE.
I keep forgetting that shortcut... :doh: Still, it's only more work to get something that should've been there automatically :) I don't see why IntelliSense support had to be different for VB and C# anyway.
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
} -
That, dear sir, conforms to lunacy. Seriously? Case sensitivity alone is reason to ditch C#? Ever hear of intellisense? As the other intelligible 'academic' above me pointed out, learning to use your IDE is crucial if you want to be a developer. Personally, I would much rather have an academic write my code than a kindergartner. They tend to think better. Good luck with your VB endeavors. I shall see you when you're done debugging. I shall now end my thoughts of anger with this period.
Member 8600767 wrote:
I would much rather have an academic write my code than a kindergartner. They tend to think better.
I know some academics... :doh: My trust in academics has often been misplaced and as a result I don't trust them anymore. I hold an academic title and as such am able to say university is a joke, at least over here :) Anyway, I'd have to think twice about the academic or kindergartner...
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
} -
Looks more like "A couple of reasons to learn how the heck your IDE works, and some reasons why C# is better than VB" to me..
-
That, dear sir, conforms to lunacy. Seriously? Case sensitivity alone is reason to ditch C#? Ever hear of intellisense? As the other intelligible 'academic' above me pointed out, learning to use your IDE is crucial if you want to be a developer. Personally, I would much rather have an academic write my code than a kindergartner. They tend to think better. Good luck with your VB endeavors. I shall see you when you're done debugging. I shall now end my thoughts of anger with this period.
I think you need to take yourself a lot less serious.
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
-
I think he was trolling. And while I agree with some of the points, I disagree with some others, and believe that several of the points has a lot to do with preference. And point four is exactly one of those where it is about your preference.
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
-
I assumed it was polemic, in an attempt to get his site looked at. In the latter point he may have been successful, but he also comes across as not knowing what he is on about so this may have backfired. What troubled me most about the article was the number of people who agreed with him. There really are very good VB devs out there, but VB does seem to still draw people who have no real knowledge and no real interest in gaining the knowledge of how things work. This drowns out the good VBers, and has much to do with VB's [undeservedly] poor reputation.
Sort of a cross between Lawrence of Arabia and Dilbert.[^]
-Or-
A Dead ringer for Kate Winslett[^] -
Member 8600767 wrote:
I would much rather have an academic write my code than a kindergartner. They tend to think better.
I know some academics... :doh: My trust in academics has often been misplaced and as a result I don't trust them anymore. I hold an academic title and as such am able to say university is a joke, at least over here :) Anyway, I'd have to think twice about the academic or kindergartner...
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
}Naerling wrote:
hold an academic title and as such am able to say university is a joke, at least over here :)
Come to Jordan, then the scales will fall from your eyes. Hell, they even let me teach ;) .
Sort of a cross between Lawrence of Arabia and Dilbert.[^]
-Or-
A Dead ringer for Kate Winslett[^] -
I assumed it was polemic, in an attempt to get his site looked at. In the latter point he may have been successful, but he also comes across as not knowing what he is on about so this may have backfired. What troubled me most about the article was the number of people who agreed with him. There really are very good VB devs out there, but VB does seem to still draw people who have no real knowledge and no real interest in gaining the knowledge of how things work. This drowns out the good VBers, and has much to do with VB's [undeservedly] poor reputation.
Sort of a cross between Lawrence of Arabia and Dilbert.[^]
-Or-
A Dead ringer for Kate Winslett[^]Well, it's not just VB. We will find people agreeing to any article about any programming language even if it is wrong at multiple levels. Although VB community is clear winner in that case.
Keith Barrow wrote:
This drowns out the good VBers
We got at least one in Dave Kreskowiak here at CP.
"The worst code you'll come across is code you wrote last year.", wizardzz[^]
-
I think he was trolling. And while I agree with some of the points, I disagree with some others, and believe that several of the points has a lot to do with preference. And point four is exactly one of those where it is about your preference.
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
-
Here[^] Now, where was that bulletproof vest? <Takes cover under a fireproof blanket> A bulletproof vest can take at least one 45ACP, right?
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
I really don't understand the C# vs VB antagonism. If you're a professional programmer, you should be able to code in both languages with same ease. When C# people roar out against VB, they're being plain childish. As are the VB people when they claim that they don't understand C#.... I code in both languages and like them both!
Why can't I be applicable like John? - Me, April 2011
-----
Beidh ceol, caint agus craic againn - Seán Bán Breathnach
-----
Da mihi sis crustum Etruscum cum omnibus in eo!
-----
Just because a thing is new don’t mean that it’s better - Will Rogers, September 4, 1932 -
Here[^] Now, where was that bulletproof vest? <Takes cover under a fireproof blanket> A bulletproof vest can take at least one 45ACP, right?
Light moves faster than sound. That is why some people appear bright, until you hear them speak. List of common misconceptions
It seems to me that C# devs should be getting on with coding instead of spending their time moaning about us VB guys. At the end of the day its the front end that matters to a customer.
Mine is not to reason why. Mine is just to code and cry. http://www.skillsmaster.co.uk
-
I really don't understand the C# vs VB antagonism. If you're a professional programmer, you should be able to code in both languages with same ease. When C# people roar out against VB, they're being plain childish. As are the VB people when they claim that they don't understand C#.... I code in both languages and like them both!
Why can't I be applicable like John? - Me, April 2011
-----
Beidh ceol, caint agus craic againn - Seán Bán Breathnach
-----
Da mihi sis crustum Etruscum cum omnibus in eo!
-----
Just because a thing is new don’t mean that it’s better - Will Rogers, September 4, 1932I am currently working on both VB and C# side by side. What makes life hell is habit of adding semi colon or using "enter" for autocomplete in VB and using brackets in C# rather than {}. Other things that I have noticed is that VB either does not have is and as equivalents or I just don't know if there is any. And yes, VB does not have out parameters too I guess.
"The worst code you'll come across is code you wrote last year.", wizardzz[^]
-
I am currently working on both VB and C# side by side. What makes life hell is habit of adding semi colon or using "enter" for autocomplete in VB and using brackets in C# rather than {}. Other things that I have noticed is that VB either does not have is and as equivalents or I just don't know if there is any. And yes, VB does not have out parameters too I guess.
"The worst code you'll come across is code you wrote last year.", wizardzz[^]
VB has both is and output parameters...
Why can't I be applicable like John? - Me, April 2011
-----
Beidh ceol, caint agus craic againn - Seán Bán Breathnach
-----
Da mihi sis crustum Etruscum cum omnibus in eo!
-----
Just because a thing is new don’t mean that it’s better - Will Rogers, September 4, 1932 -
OriginalGriff wrote:
- And what do you think ReDim Preserve is doing behind the scenes? At least with the C# version it is obvious that this is going to consume time and memory...
The whole point conveniently ignoring the obvious solution, which would be that if you want to go around resizing your arrays you should use something like
List<T>
and not a regular array in the first place.-SK Genius
Vehicle Simulation Demo - New and Improved!
Yep. I almost never declate arrays these days - with the exception of byte[] and so forth to handle conversions between image and stream. But the existence of ReDim encourages the lazy to use an array - not thinking about the wasted memory and effort it involves behind the scenes.
Ideological Purity is no substitute for being able to stick your thumb down a pipe to stop the water