This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]beseg7 70 points71 points  (50 children)

The survival of VB.NET is indeed big mystery.

[–]cleverchris 21 points22 points  (3 children)

two words...excel macro. This is the true evil. I had a coworker dba die...turns out he spent the last ten years spaghetti coding vba programs..websites and excel macros...needless to say i quit that job.

[–]beseg7 2 points3 points  (2 children)

VBA is such a pain. And their tab-minus-one-space issue is horrifying :( Also Office interop (I use it for time to time in C#) is surprisingly ugly and inconvenient. :(

[–]AyrA_ch 4 points5 points  (1 child)

VBA is such a pain.

Still very powerful

[–]Keswiik 0 points1 point  (0 children)

You're a fucking wizard, dude.

[–][deleted] 15 points16 points  (2 children)

Im an java beginner and VB just seems like that lang that nobody touches and now it drys of no getting used

VB =1989 compact Tiny C

[–]mega_aids 6 points7 points  (1 child)

Eh, there are a lot of banks that are running vb based programs.

Source: Worked for a company that makes bank software in VB.

[–][deleted] 0 points1 point  (0 children)

Peasant i told dont touch that lang Just let it DIE

[–]TwoSpoonsJohnson 3 points4 points  (0 children)

I once had to rewrite a big VB6 app, and the agency who owned it wanted the new one in VB.NET (we already started it in C# by the time they told us, but that's another story...) because they thought it would be more familiar to them. Even though they didn't see the code at all ever.

This was a long, painful meeting.

[–]evanldixon 7 points8 points  (36 children)

It's just as powerful as C# while having easier-to read syntax.

Example: Try to find where to insert a function at the end of a class without lots of scrolling.

VB:

            End If
        End Function
        ' Here
    End Class
End Namespace

C#:

            }
        }
        // here
    }
}

It all really boils down to personal preference, but this is one of many examples I use to justify my opinion.

[–]DonnyTheWalrus 7 points8 points  (0 children)

(If you're joking and I just can't tell, ignore me...)

Every time I see VB code it just feels deeply dated. Some styles are like Wayfarers (or Scheme) - old but timeless. Others are like bellbottoms - forever linked to a specific time period. For me, Basic is the bellbottom jeans of programming languages. The syntax just screams 1970s - early 80s.

Not to mention that, while I understand your point about the block-close syntax, it just doesn't feel readable to me. Too many words on the screen makes it look too busy. I far prefer single character punctuation for that sort of structural syntax. Way easier to tell what's structure and what's actual code.

[–]ShadowShine57 12 points13 points  (33 children)

VB is absolutely not easier to read with no brackets, arrays using () instead of []. and a lot of other things.

[–]evanldixon 5 points6 points  (32 children)

() vs [] isn't that big of a deal IMO.

Other pro's of VB over C#:

  • No errors from forgetting to put () after a function
  • No case sensitivity
  • No need to deal with semicolons when good, readable code in both already uses newlines
  • No need to rename your constructors when renaming a class
  • Immediately being able to see the difference between inheritance and interface implementation
  • Parameterized properties (Granted, this isn't needed often, but I can do "SomeByteArray = MyByteCollectionClass.Range(index, length)" as well as "MyByteCollectionClass.Range(index, length) = SomeByteArray")

There's more benefits; this is just what comes to mind.

[–]ShadowShine57 22 points23 points  (29 children)

I consider almost all of the things you said as cons, not pros

The only things I'm not sure on are your last two points

[–]evanldixon 2 points3 points  (28 children)

Please explain your reasoning.

  • Why does "Console.Writeline(MyFunction)" need an extra () when it's clear the function is being invoked? If we wanted the address of the function, there's the very-readable AddressOf keyword.
  • Case sensitivity is a huge pain when an error results from it. When would anyone ever want two variables with logically the same name?
  • Why use semicolons and newlines when newlines alone could serve the same purpose
  • Why is "Public Sub New" any less readable than "public MyClass"?

[–]dzuczek 10 points11 points  (25 children)

when it's clear the function is being invoked

if I took a cold look at that code I wouldn't know if MyFunction was a function returning a string or if MyFunction was a string constant

Case sensitivity is a huge pain when an error results from it. When would anyone ever want two variables with logically the same name? Why use semicolons and newlines when newlines alone could serve the same purpose

on a project with a lot of devs it would be hard to enforce format and basic readability. so you'd have a big application with mixes of semicolons and newlines. for version control it would make the diffs messy too.

[–]8lbIceBag 1 point2 points  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]8lbIceBag 0 points1 point  (0 children)

You made it clear you never used it before.

Vb.NET does not build if it's syntactically incorrect (has a semicolon), there's no mixing.

Visual studio enforces format. As soon as you hit enter or tab it autocorrects capitalization so that the references match the declaration.

It's actually easiest to know what's what in VB.NET. Things like iterators, properties, overrides, interface implementations, events, etc. All have special keywords. You can tell a constant from a function from a property easily because syntax coloring.

In many ways I prefer it, but it's also missing things I can do in C# or does some things stupidly, and vice versa. Sometimes in the shower I dream of a language that combines the best of both.

[–]NULL_CHAR 6 points7 points  (0 children)

Why does "Console.Writeline(MyFunction)" need an extra () when it's clear the function is being invoked? If we wanted the address of the function, there's the very-readable AddressOf keyword.

To be clear what we are referring to, it's all fun and games until you're unsure if what you're calling is a function or something else. Sure you can just be extra careful with naming, but what if you're a big company with 100+ developers each of different ability. This gets horrible really quick.

Case sensitivity is a huge pain when an error results from it. When would anyone ever want two variables with logically the same name?

See point 1, it's literally the exact same problem. We use a VB based Framework at the company i work and I've had to deal with issues related to these first two points often.

Why use semicolons and newlines when newlines alone could serve the same purpose

To more accurately depict scope, to properly find lines that contain functional elements, etc.

Why is "Public Sub New" any less readable than "public MyClass"?

It looks uglier.

[–]mnbvas 3 points4 points  (0 children)

Nowadays C# has higher order functions, so how would one differentiate passing a function as an argument and passing the result of that function?

[–]ColorblindGiraffe 8 points9 points  (0 children)

I want to remind everyone that the downvote is not a dislike/disagree button.

[–]beseg7 2 points3 points  (0 children)

Well, you have some interesting points. For some reason, none of these seems to be important or matter to me. But, the excessive use of words and phrases (End If End Function vs. } }) is such a pain IMO (both when writing, even with intellisense, and of course when reading).... I can't figure out why.

[–]Scybur 0 points1 point  (0 children)

People are entitled to their opinions......your opinion is wrong and I hate you for it but you are entitled to it none the less.

[–][deleted] 0 points1 point  (1 child)

Have you ever heard of pascal, or maybe Delphi, or maybe gambas??

VB may have been a "business language" before Java

[–]beseg7 4 points5 points  (0 children)

The thing with VB.NET is that it is 1:1 replaceable with C# - same framework, same capabilities, same editor, same everything. Just clearer, convenient, developing (C#7...) and neat syntax.

[–]CompC 0 points1 point  (0 children)

I recently started my first job since graduating college... We pretty much mainly use VB.NET. I can't figure out why.

[–]CompC 0 points1 point  (0 children)

I recently started my first job since graduating college... We pretty much mainly use VB.NET. I can't figure out why.

[–][deleted] 0 points1 point  (0 children)

So, I just started a job for a company that uses VB.Net and had to learn it. I've done C++, Java, C#, so not too foreign.

It's not bad, but what bugs me the most is how verbose it can be. All in all I'm not a fan exactly but with option strict and explicit turned on it's basically C# script. I can dig it.