3 ms·
I did this a number of times. I started working on a VB.Net source base around 2007 and started to introduce C# as soon as I could, then next job in 2013 was al
by memsom 5y ago
I did this a number of times. I started working on a VB.Net source base around 2007 and started to introduce C# as soon as I could, then next job in 2013 was also a WinForms app that embedded some WPF and used mainly VB.Net and some C#. I have to say, C# feels a lot more productive for me. I can switch between C# and VB.Net easily, but some of the stuff VB.Net does makes no sense.
The 2007 project was a mess when I inherited it - the contractors who wrote it were based in India, and the code looked like a VB6 project. They had not turned on option explicit or option strict. They did not understand how events or event handlers worked - they added handles clauses to methods then assigned a variable with the current instance to make the events happen. It was bizarre. They also did a lot of horribly hacky things because all the variables were basically being treated as variant. There was even a bit of code where they had a select case statement where a Boolean variable was being used as a case... and I mean it was doing a select case on and integer, and one of the cases was a Boolean variable. So it depended on what that was set to as to what the case did. I turned on option strict and explicit, took a deep breath, and fixed the hundreds of errors. It was BRUTAL! I'm not saying this is something that is an issue with VB, that was down to the programmers not being trained properly and making some very bad decisions. But in C# it would have been very hard to make the same mistakes.
By the time I left the 2013 job in 2018, I had divorced myself from almost all of the VB.Net code and I swore I would never touch VB again. So far, so good.