r/learnprogramming • u/pyeri • Sep 15 '24
.NET What caused the sudden death of Visual Basic and the corresponding rise of C# in .NET world?
If you go back to 90s or even early 2000s, Visual Basic was the more popular language for building apps and software on the Microsoft stack. But then all of a sudden, C# saw a sharp rise in its usage and VB.NET sort of dwindled, be it in the corporate or open source world.
But if you think about it, both VB.NET and C# are CLR languages which follow a similar language structure, "object-orientedness" and share the exact same runtime (libraries like System.Net.*). One has no particular advantage over the other from functionality perspective. The only advantage C# has is that it's similar in syntax to Java/C, thus making the transition somewhat easier for those coming from that particular language ecosystem.
Some folks blame Microsoft for the death of VB.NET but I don't think that's entirely accurate. Visual Studio has full support for both these languages (apart from a few other .NET languages). What they use internally for their open source projects should not impact the decision of .NET programmers in general.
56
u/RoughCap7233 Sep 15 '24
From memory:
22
u/Savacore Sep 15 '24 edited Sep 15 '24
In the 90s everybody was using VB1 to VB6. It was never big in the .NET world
Microsoft completely upended the VB development ecosystem with VB .NET, which was more like C#. You had to retrain and rewrite your apps from scratch if you wanted to use it.
Frankly, it was just as easy to go to C#, (and it was even easier if you were starting from a similar language like Java)
And since a java replacement was what people actually WANTED out of .NET, Visual Basic never really got a foothold there. It mostly died with 6.
6
u/plastikmissile Sep 15 '24
It's not entirely accurate, but it's not entirely inaccurate either. When .NET first became a thing, the two major languages were (as is now) C# and VB.NET. C# was envisioned as the Java killer. A cleaner language with familiar syntax that occupies the same niche. While VB.NET was designed with the hordes of VB6 devs in mind. It was envisioned as a way for them to easily transition to the new .NET environment. There were some teething problems as programmers discovered that any resemblance between VB6 and VB.NET were only surface level. This lead to the reputation of VB.NET being a terrible language, mainly due to the terrible quality of early VB.NET production code as many VB6ers were fumbling around trying to apply what they know on a completely different architecture. So while VB.NET started out being fairly popular, it gradually lost audience to its prettier sister C#. And so, MS started to put more emphasis on developing C# features, while VB.NET basically less and less dev time. This lead to VB.NET lagging behind C# which of course only exacerbated its decline in popularity.
3
u/iamcleek Sep 15 '24 edited Sep 15 '24
MS pushed C# and .Net very hard when it was released. .Net was designed to be a secure and safe environment that got people away from the dangerous aspects of C/C++ and from the sloppiness of VB. C# succeeded because it works on both counts, while still providing performance and flexibility. so, managed C++ and VB.Net seemed rather pointless - they were too different from their predecessors for backwards compatibility, so you were going to be starting over no matter what; might as well go with what looked to be the best designed of the three: C#.
3
u/frobnosticus Sep 15 '24
You've got the right of it.
VB predated .net.
Java came out and they said "Ooh!" and released Visual J++ and were promptly told "bad monkey no biscuit, you can't do that."
So C# came out. vb was ported over but couldn't really stand up to C# (vb was always a garbage language, even though the toolset was pretty damned slick) so it died on the vine in all but name.
I'm not sure it's really used for anything other than office automation and scripting in a practical sense.
2
u/Lamington_dommondke Sep 15 '24
The rise of C# can be attributed to its modern features and closer alignment with the evolving .NET framework, which overshadowed Visual Basic's older syntax and paradigms.
2
u/MikePGS Sep 15 '24
A meteor.
2
u/thinkjohn Sep 19 '24
I write all my companies LOB windows desktop applications in VB.net and win forms. If I did not tell you the language I use, you would not be able to tell the difference.
Sole developer with over 20 apps that are between 1 and 15 years. Some have 10 screens some have hundreds.
It is all about building solutions. That is what I love about VB.net. I can build almost any solution.
Xamarin iOS apps require me to use C# but the web services and integrated business layer and data layer are VB.net.
Visual Studio is the real star. I can do it all in the same solution.
Just wish VS allowed multiple solutions open in same instance, but that is another topic all together.
2
u/dswpro Sep 15 '24
Visual basic died a death IMHO because Java was fulfilling the promise of "write once run anywhere" and Microsoft's cash cow, their operating system sales, were vulnerable. Quite literally C# was spawned from Java Envy.
1
u/jeffrey_f Sep 15 '24
VB.net was more for the application and essentially allowed a non-programmer (the user) to build some level of automation into something like excel. I used to to some degree to allow my sheet to rebuild itself upon opening as the data was from external sources.
I think that once Office 365 took hold, VB and its flavors were no longer necessary to some extent for the end user.
1
u/bear007 Sep 15 '24
Microsoft didn't invest in Visual Basic so much since the inception of C#. C# was inspired by Visual Basic making it a natural successor
1
u/stlcdr Sep 17 '24 edited Sep 17 '24
C# and VB were the same under the .net umbrella - they still are.
C# pulled ahead as C and C++ programmers migrated over to C#. Thus C# gained dominance.
C-style languages tend to have greater penetration across all (development) markets.
1
u/BenjaminGeiger Sep 15 '24
My hypothesis is that VB.NET was just different enough from VB 6 that the people who already knew VB 6 effectively had to learn it as a brand new language.
My first job out of college was in a school board data processing department that was almost 100% VB 6. The legacy system was a 1.25 million line steaming pile of VB 6, mostly written by an outside company that they bought the code for. (It's a long story.) But my position wasn't working on the legacy system, and it was a long fight to convince the Powers That Be to let me use C# instead of VB.NET.
1
u/Saki-Sun Sep 15 '24
I can only guess at what really happened. But I can tell you my story and it might help make sense of it all.
I was a VB developer supplemented with classic asp . But day in day out I did a lot of VB.
VB 6 and its predecessors had a reputation of how do I put this politely. Not having the best programmers working with it. So to not get pigeonholed I did as much java, C and C++ as I could.
Then dotnet came out and all the VB developers moved to VB.Net. I moved to writing C# at home and VB.Net at work because I loved C and didn't want to get pigeonholed as a dirty VB developer.
Whenever I changed jobs I would choose C# over VB.Net. Occasionally I would have to go back to a VB house and it was filled with ex-VB6 developers that struggled. Most of them could program all right, but they had kids ect and it was just a job, not a passion.
Eventually I just took VB off my resume and stopped applying for those jobs. There was just more tallent in the C# world.
1
u/[deleted] Sep 15 '24
VB required a DLL on the client box. I had a coworker who wrote a VB system for fulfillment. Every time they set up a new client, they would swear the system was broken. His boss finally got sick of the complaints and wanted it rewritten.
1
u/pjc50 Sep 15 '24
Web applications won over desktop applications for the kind of company specific "line of business" apps that people were writing in VB.
1
u/InvestigatorOk114 Sep 15 '24
My experience in the early .net days was that c# devs were considered to have a higher skill level than vb.net, and earned higher salaries.
That was the reason I switched to c#.
0
u/[deleted] Sep 15 '24
Visual Basic wasn't very fun to program in. It had all kinds of weird syntax/design quirks, and there were a lot of tasks that were infeasible to do with it. It was my first programming language ~16 years ago.
-1
u/gidmix Sep 15 '24
The web targets all devices so everyone moved to the web. Visual Basic does not run on Apple,iOS or Android.
C# is more suited for server side programming and everything was moving towards website. Deployment of client app changes was a pain in Windows meaning VB was just not feasible anymore.
0
u/tjsr Sep 15 '24
VB was much, much easier to use by the masses than MSVC and MFC for UI development. When C#, then the .net framework, then WinForms came along, it was pretty much the first nail for VB. It bridged that halfway point in the difficulty many had working with C while providing all kinds of great solid language features under C#.
What really did it was ASP.net having C#. VB.net survived for a long time but ultimately C# being available in that ecosystem really bought it home.
-2
u/Jim-Jones Sep 15 '24
C and versions of it are encouraged by teachers at colleges etc.
BASIC and versions of that are deprecated.
-2
u/Rainbows4Blood Sep 15 '24 edited Sep 15 '24
In my experience, VB and VB.NET have nothing to do with each other. One being basically a scripting language and the other one a fully compiled programming language.
VB is mostly dead because there are better ways to automate things nowadays such as PowerShell Scripts and Python.
VB.NET is dead because when it released in 2002 alongside C#, there was little reason for anyone to adopt it.
I still see people in companies automate some things with VB. I have never seen anyone program in VB.NET.
EDIT: I confused VB with VBScript. But the rest of my point still stands. C# essentially crushes VB and VB.NET for Windows development and so it became the de facto Standard used by Microsoft centric developers.
-1
u/Aglet_Green Sep 15 '24
Money. The answer to most business decisions is the bottom line which is to say, making or losing money.
-3
u/alien3d Sep 15 '24
i start qbasic the vb 6 then vb.net . What changes ? php . It fast and easy and when moved back .net sudden c# and forget the vb era . 😂. Some newbies programmer kinda annoy thinking they is right way but is not . Just build solution and solve problem.
0
u/[deleted] Sep 15 '24
[deleted] — view deleted comment
0
u/[deleted] Sep 15 '24
[deleted] — view deleted comment
114
u/[deleted] Sep 15 '24 edited Mar 15 '25
[removed] — view removed comment