Better Living Through Technology!

Main menu

Post navigation

What I like About Visual BASIC .net

I admit I’ve used BASIC my whole life in one way or another. As a kid, it came on all the computers. As an adult, Microsoft’s Visual BASIC 6 was a revolutionary way to design Windows programs. And today, VB is the ‘other way’ to program in .net – not as hot as C#, but perfectly usable.

And better, I believe – here’s why:

Syntax. I like C’s terse syntax. But sometimes I tire of adding ‘;’ after everything. And I didn’t realize that until I had worked in VB .net for awhile. And having the IDE manage the formatting, while a tad controlling, saves me space-space-spacing to reformat lines all the time (and yes I know most everyone has a prettyprinting option in their IDE, but it’s funny how often “don’t bother using it – it’s just one line” pops up in coding…)

Case insensitive. It seems small, until you use it for awhile. If I create a variable called “buffLen”, I can write “bufflen” everywhere, and the IDE will automatically adjust it to “buffLen”. Like the “;” key, not having to hit the shift key is noticeable when I go back to C.

It gets the job done. Don’t get me wrong – I like C/C++ and I’ve done most of my development in it. But whereas C can feel like tuning a high performance car at times, VB feels like popping into the van for a trip to the store. You still need to change the oil – but one takes a lot less effort to do things with. And for most programming tasks, just getting it done is fine. For example, GUIs work at human speeds – so is the extra performance of hand-tuned C worth it in that case?

The IDE. This should be multiple points, but the Microsoft IDE makes it very easy to program VB. Start typing, and it prompts with the obvious choice. Can’t remember that object’s function name? Press the period, and a list pops up. Same for variables. And I’ve already mentioned the autoformatting and variable case insensitivity.

It’s portable(ish) A huge benefit of C is portability. With Microsoft’s foray into Linux, Mac, and Handhelds (via Xamarin) the knowledge of .net is leveraged. Time will tell if they extend support for VB, but let’s hope.

I’m not a fan of propriety languages, but the convenience of VB for projects has me moving to it as my goto language for little glue programs in my work. It’s faster to prototype and test, gives me a GUI simply, and has a very good collection of collections (lists, dictionaries, etc) so I get small apps up and running quickly.

You may disagree – but choice is the spice of life, so perhaps you’ll prefer the next article, where I discuss C/C++ and why I like it – because I can have two (or more) favorites…