VB6 vrs .NET (again)

Author: Dave
Date: 10.03.12 - 5:16am

So .NET is now almost 11 yrs old (Feb 2002). VB6 is almost 15, (1998).

I tinker in C#. There is a lot of existing code now for it that can save me time. The .NET framework and having large debugged libraries available is nice, but there are still tradeoffs.

Vb6 is a dead language according to some definitions. In reality though, since it still works, its actually one of the most stable languages you will find. No break neck innovation, no one is whipping up new features that keep your head spinning. Its a stable environment. We know what it does, we know what it doesnt do, and there is a load of public code available for it.

If you arent familiar with the VB6 IDE, here is a quick video I made showing its strengths and a few reasons I still use it.

One gripe with vb6 was that it needs the 1mb vb runtime installed in order to run on a system. Also if you wanted other features such as listviews, or progress bars you had to include references to external ocx or dll files which made distributions harder.

.NET actually took that mess to a whole new level. At the present moment I have 4 seperate versions of the .NET runtimes installed on my system each taking up hundreds of MB of disk space, and each requiring at least 20-30 minutes to download and install.

How about all of the fancy features of .NET compared to the basic class structures of vb6? Honestly I find vb6 simpler and more direct. Typing in .NET code is very verbose, as you walk your way through the different classes and enums. Also all of the advanced object oriented class features such as polymorphism. They are stressed a lot, but in reality you can write an awful lot of code without having to use such features. Complexity and error are closely related.

Granted there is some liability in using VB6 for new products. There may come a day when it will cease to operate or bugs crop up in future operating systems, or more likely, that you will need some capability that cant be done in VB6 cleanly.

How is it that a decade latter, I still find myself reminiscing, and ranting on the new architecture? I guess to me, VB6 is still my perfect "get shit done quick" language due to its directness and simplicity. I am also lucky that I only really write research applications.

A danger of new technologies is that they tend to thrash about in the evolution process. Thank god i didnt start developing any code for windows phone! They have had several complete incompatible shifts in technology over the years and the phone still has poor market share.

Its amazing how many boutique programming languages are out there. This even extends to corners of the .NET framework such as WPF.

Mastery is being able to obtain a simple elegant answer even while interfacing with a complex (or even chaotic) system. Stability is virtuous.

Comments: (10)

On 11.18.13 - 11:47pm Daniel Duta (Bucharest, Romania) wrote:
Hello Dave, It is more than a blog, I would say it is a programming tutorial. I was very happy when I read your opinions regarding VB6 vs .NET. It is interesting that a young guy like you has such a philosophical view of programming - Complexity and error are closely related. Another guy, Olaf Schmidt (unfortunaly banned by si_the_geek after a technical debate ...), has similar ideas considering that VB6 is more open to improvements than other languages and he preferring to spend time in this sense - see his site www.vbrichclient.com . Your both views are even more interesting to considering the new generation madness regarding C#,Java, phone apps Android. I really love your inline injections within VB6 and often I feel you are able to reveal pieces of a lesser-known world. Good luck! This weekend I will read all your post from the blog.

On 12.06.13 - 6:10am Dave wrote:
One more additional thought. The more complex tools you give people, the more complex "solutions" they may come up to problems. I am reading through someone elses code right now. They are making things way more complex than they have to such as using a delegate set in an if else statement, instead of just calling the desired function within that same if else. Or declaring functions as static needlessly which then has effects on member accessibility. Complex language attributes can (in the right situation and in the right hands) equal elegant solutions, but for the majority I think it just makes a needless mess.

Another: .NET throws allot of needless errors. Clipboard.SetText(0 length string) = exception. really? I dont care, I just cleared it. There is no value to that exception. Im also not shy in saying i still love On Error Resume Next. there are allot of things its perfect for such as form resize code.

On 12.16.13 - 5:43am Dave wrote:
here are a couple more ways .net ide is inferior to vb6
  • the code navigation combo boxes at the top of the editor window, in vb6 you choose the object on the left one, and the events on the right, in .net 2008 they are all jumbled together on the right.

  • break and edit, in vb6 hitting pause put the entire codebase into source editable mode. you could make changes on the fly really easily. in .net you have to set a breakpoint and hit it before you can edit live. also the edit and continue is problamatic. not all changes can be applied like this

  • The class/property hierarchy is so loaded with crap, including base object methods that the intellisense menus are miles long instead of being clean and concise. Some people may argue the extra features are worth it. I am not one.

  • vb6 supports optional arguments. waaay better than having to write a bunch of stubs for overloads, which you then have to click through one by one to see them all in the bulky intellisense menu. wtf really?!

On 01.20.14 - 4:13am BioMeg wrote:
Visual Basic 6 is the best ! Thank you for this video Dave.

On 02.23.14 - 4:00pm Dave wrote:
Another one I dont think I have mentioned yet. I LOVE that VB6 does not have a default null type for variable and function returns. It is so nice being able to just exit function and know that the default value of the return is false for booleans or an empty string. It makes your code way more readable and all of those null object checks you have to liter your code with C# have negative value in my book. A higher level language should do more for you, not require you to be super anal.

On 02.23.14 - 4:02pm Dave wrote:
also @BioMeg, I saw the advanced submissions you have tracked down and are keeping alive on PSC. Thats a great idea, thanks right back :)

On 04.06.14 - 12:53pm Sten wrote:
Dont forget the Vote for an updated VB6 at http//visualstudio.uservoice.com/forums/121579-visual-studio/suggestions/3440221-bring-back-classic-visual-basic-an-improved-versi

On 06.28.14 - 9:11am Dave wrote:
Here is a succinct definition of why I cant leave VB6.

It is a simple and direct language without over complication. It is fast and can do 90% of my general programming requirements directly. For the other 10%, it can integrate very easily with C/C++ through either COM or direct API declares.

its still a winner, and I will use it until something better comes along...

On 06.07.17 - 9:40am VB6 Programming wrote:
Microsoft support VB6 for the lifetime of Windows 10, so until at least 2025. And for the lifetime of Windows Server 2016, until at least 2027. https//docs.microsoft.com/en-us/dotnet/visual-basic/reference/vb6-support

On 05.26.24 - 8:24pm Sten wrote:
The new twinBASIC programming language can import VB6 source code.

Leave Comment:
Email: (not shown)
Message: (Required)
Math Question: 95 + 91 = ? followed by the letter: Y 

About Me
More Blogs
Main Site
Posts: (All)
2024 ( 2 )
2023 ( 9 )
2022 ( 4 )
2021 ( 2 )
2020 ( 4 )
2019 ( 5 )
2018 ( 6 )
2017 ( 6 )
2016 ( 22 )
2015 ( 15 )
2014 ( 25 )
2013 ( 4 )
2012 (10)
     VC 2008 Bit Fields
     Speed trap
     C# Db Class Generator
     VB6 vrs .NET (again)
     FireFox Whois Extension
     git and vb6
     Code Additions
     Compiled date to string
     C# ListView Sorter
     VB6 Wish List
2011 (7)
     C# Process Injection
     CAPTCHA Bots
     C# PE Offset Calculator
     VB6 Async Download
     Show Desktop
     coding philosophy
     Code release
2010 ( 11 )
2009 ( 3 )