VB.NET vs C# - A comparison of the two languages, how they are different, and where they are going

preview_player
Показать описание
VB.NET and C# are both .NET programming languages. They both compile down into the same intermediate language. So which language should you choose to develop in? Does it really matter? In this video, we are going to discuss the origins of VB.NET and C#, look at the two languages side by side, and look to the future of each as well. By the end of this video, you should have a much better grasp on why each of these languages exists and why you should choose one over the other.

0:00 - Intro
2:20 - Visual Basic history explained
5:52 - Building VB and C# libraries
8:43 - Writing code for C# library
15:00 - Writing code for VB library
27:58 - Calling the libraries in the application
32:00 - Conclusions
33:06 - Co Evolving VB and C#, popularity, direction.
Рекомендации по теме
Комментарии
Автор

Why do developers who criticize VB say it immediately succeeded BASIC while ignoring that Microsoft created an intermediate BASIC that introduced modularity. It's called QBASIC and I don't trust anyone's authority or criticism who is not aware of the real predecessor to Visual Basic. Not all programmers are hired gun developers. Some just enjoy coding and like to make programs that work for a selected venue.

anthonynorton
Автор

In the Stackoverflow 2019 survey, VB.Net was not on the list to chose. Therefore the survey is wrong when it comes to determining popularity of VB.Net

louigta
Автор

There is no language like VB.net ... more than 15 years working as a developer, used many languages, but honestly, I do not find a language like vb... in .net example, it has the same capabilities and performance of c# and much easier and the code is more readable.
for my opinion vb is the best language

bazkhaldoun
Автор

VB.net is much more readable which makes it much more maintainable. Thankfully RemObjects Mercury will continue to develop, enhance and support VB.net so millions of programmers can continue down this saner path. After all why learn C# when just a little more effort you can learn C++ which gives you much more control.

mrright
Автор

0:00 - Intro
2:20 - Visual Basic history explained
5:52 - Building VB and C# libraries
8:43 - Writing code for C# library
15:00 - Writing code for VB library
27:58 - Calling the libraries in the application
32:00 - Conclusions
33:06 - Co Evolving VB and C#, popularity, direction.

RalfsBalodis
Автор

VB.NET is basically Microsoft's red headed stepchild. Everybody tries their best to forget it exists. Microsoft themselves forgot about it in .NET Core 1.0. There's no reason to know VB.NET. There are far more resources, code examples and tutorials in C# on the Internet. Search a .NET related question on StackOverflow or Google and 99.9% of the time you will get your question and answer in C#.

briankarcher
Автор

I prefer vb.net. dont like case sensitive in c#. Any way around ie textbox1.text and c# doesnt automatically cinvert to textbox1.Text

gbmarshall
Автор

Thank you!

Just joined a company that has a mix of both C# and VB.Net. I haven't used VB since pre-college days 🙃

Bonezz
Автор

C# has too much syntax baggage. More questions are asked about C# because it is harder to learn. VB.net translates to human thought better than C#.

MrModify
Автор

Here I'm telling you a secret, don't tell anyone:
You will find hundreds of useful methods in its assembly (Microsoft.VisualBasic.dll) which I often imported to my C# projects

arwahsapi
Автор

Hi, Tim
I'm a VB developer from day one of VB 6, with Visual Studio 2010, almost 8 years I'm in VB.NET until December 2018 when I received solution written in CSharp. I was sceptical, can i learn CSharp and continue to work on received solution. Thanks to you with great and detailed videos, i watched almost 40 hours, I'm now all i CSharp. Definitely CSharp is the way to go. Thanks
P. S. For quick small code testing I'm still using VB.NET, it's easier for me 😀

decmk
Автор

VB.NET vs C# is indeed just personal preference, I prefer C# because porting C++ or Java code to C# and vice versa is very easy, VB is to "wordy" to my taste. VB is nice to people that have 0 programing experience.
BTW, we should BAN { } for single lines.

ClassicGameHacking
Автор

Your vb for/next loop would be better as: For index as int32 = 0 to lines.count -1 int32 being the variable type. It is clearer and will execute faster.
Another for/next example: For f as double =0 to .9 step .01

ps. I know this is intended as a quick comparison and not a lesson on vb.net but the As... can make a big difference to the performance of your code.

philgriffin
Автор

Worked with VB.NET for 8 years, C# 5 years.
I think VB.NET is still superior in desktop application, primary because WithEvent keyword.
Syntax is more readable, especially in multiple nested loops or ifs.
Yes, it has more letters, like End Class, but you do not write them. But delegates can get a little messy. Also "AndAlso" (C# &&), "OrElse" (C# ||) keywords are bs :/
For me, a lot of C# syntax errors is variable letter wrong case, writing single "=" in if, naming variable before datatype and that ";". All solved by VB.NET.
My issue with C# syntax is its origin, that was created for ancient computers to compile more easily. So it solves problem that no longer exists.
PS. Dim output As NEW List(Of String)
PS. Writing VB.NET code, more often I search for C# or just .NET
So sad VB.NET gets no love.

DreigoUndead
Автор

Thanks for the great video again. I also studied VB at university but transitioned to C# almost immediately after graduating. I found in the industry in my area more people were using C#.

StudentCompanion
Автор

i use vb net since 20 years, i think i will never change. I tried to learn c# but i realize that vb net is much better
this is my opinion

viessemondo
Автор

Great video, thanks. Love the syntax of vb.net, gonna switch to c# in the future (cause I have to, not that I really want it ;)).

in_absentia
Автор

Thanks man, i asked you about the difference between them a while ago, and you really did it *-* you're a great man.

feitan
Автор

The best part of VB.NET is that no-one can give you grief over where you put your curly braces.

IndellableHatesHandles
Автор

When I was a teenager, I didn't go to school anywhere because of economic problems. But I like to make some applications and I learned VB language self-taught, Until many people bought it. And now I want to learn C# language, thanks for sharing the information.

Taskiman