VB.Net vs C#.Net in Visual Studio

foozball3000

Executive Member
Joined
Oct 28, 2008
Messages
5,929
Reaction score
1,738
Location
Kyalami
What's the difference?
I know that for small programs, there's no difference and it's then just a matter of preference.

But, yesterday I encountered a weird problem in VB.Net and I'm pretty sure that if I've done my program in C#, that wouldn't happen.

In a For loop, I create a new String()() array. So, I thought that each time the program loops around, the variable will be dropped and recreated. Needless to say, that I didn't have a Values() = Nothing command at the end of my loop... and that was the problem. (Took me hours to find it)

Any thoughts on this?
 
Ahh the grand old debate....

For me the killer is the syntax!

I have better things todo than type so much
If () Then
End If

And then there is a small matter of case sensitivity... but the list is a lot longer than that!

Jip. That's why we generally do the odd small program in VB. Larger ones we do in C#..
 
C# and VB.NET compile to the same p-code, so in theory there is no difference.

Also, any variables you create are managed by the garbage collector, so they don't neccesarily get deleted when they go out of scope. They only get deleted when the garbage collector decides to delete them, which is why you should always initialise you variables after you create them.
 
I use all 4.
VS 2008
Visual Basic
Web developer
C#
C++

For me all the same but C# and Vb.net requires NET.Framework.

I prefer C above all but a bit complicated.
 
What's all this about typing? Ever heard of if<tab><tab>? I use the snippet shortcut constantly - no matter the language. Same goes for Intellisense - CTRL+ENTER saes me so much in the way of typing that I miss it elsewhere.

VB has optional parameters. C# (3.x) has anonymous delegates, etc. Choose your poison. At the end of the day it's the final product that counts, people!
 
All 4 IDEs, dumbass. ;)

[Disclaimer]I picked up the word dumbass from Jeff Dunham's beloved Walter. I type it (the phrase) with the utmost respect. Blame him, not me. :D

I thought this topic was about topic was about VB.NET vs C#! So if Visual C++ also gets thrown into the mix, what's the fourth one? J#? :p

/disclaimer noted
[walter voice]eehhh-he-he-he-he-he[/walter voice]
 
Actually, upon checking the post (I use all 4), Ismail then goes on to list not 4, but 5 IDEs. :confused:
 
Top
Sign up to the MyBroadband newsletter
X