Click here to Skip to main content
15,905,612 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Vb 6.0 Pin
Dave Kreskowiak13-Apr-05 8:24
mveDave Kreskowiak13-Apr-05 8:24 
GeneralRe: Vb 6.0 Pin
Bahadir Cambel13-Apr-05 11:31
Bahadir Cambel13-Apr-05 11:31 
GeneralRe: Vb 6.0 Pin
Bahadir Cambel13-Apr-05 11:57
Bahadir Cambel13-Apr-05 11:57 
GeneralRe: Vb 6.0 Pin
rwestgraham13-Apr-05 12:58
rwestgraham13-Apr-05 12:58 
GeneralRe: Vb 6.0 Pin
Bahadir Cambel13-Apr-05 14:15
Bahadir Cambel13-Apr-05 14:15 
GeneralRe: Vb 6.0 Pin
Christian Graus13-Apr-05 15:12
protectorChristian Graus13-Apr-05 15:12 
GeneralRe: Vb 6.0 Pin
rwestgraham13-Apr-05 19:15
rwestgraham13-Apr-05 19:15 
GeneralRe: Vb 6.0 Pin
Christian Graus13-Apr-05 19:28
protectorChristian Graus13-Apr-05 19:28 
rwestgraham wrote:
You never answered my question: "What significant capabilities does C# offer that VB.NET does not?"

You're asking the wrong question. I never claimed that this was the case, at all. VB.NET is crap, not because C# has more capabilities ( this would make C# crap, as C++ can do more ). It sucks because it is dragged down by legacy 'features' that Microsoft were forced to provide to keep the VB6 monkeys happy. For example, any language that auto generates return values for you is creating far more opportunities for hard to find bugs than any C++ switch statement could create.

However, here's a list I keep on my desktop ( I didn't write it, but it covers most things I would mention, and I like how it's worded )

1. The absence of the "using" statement for calling IDisposable creates resource-hungry programs. VB programmers simply do not call IDisposable, or do not call it in a reliable way.
2. "Unstructured error handling". Aka "On Error Goto". Aka bad code.
3. "On Error Resume Next". Aka "On Error F**k off". This is one of my favorites: in case of an error, resume the execution point on the next statement. Lots of fun here.
4. "On Error Goto 0" and "On Error Goto -1". I'm yet to find a VB programmer who can tell the difference between the two.
5. The "Mid" statement. No, not the function, the statement. Isn't it a work of a genius naming a statement and a function with the same name?
6. "Modules". Aka "I don't need any stinking classes". Aka "I won't ever need thread safety"
7. The "With" statement. Aka "I don't need any stinking methods. I manipulate an object outside the class definition and I call it information hiding". Aka the "data class" bad code smell. Aka "deriving a class is too much work".
8. "Option Compare Text". Aka "I don't need performance when comparing strings"
9. "Option Explicit Off". Aka "There's only one type, the powerful Object". Aka "I want to give away performance because I'm lazy typing variable declarations". Aka "I don't want a compiler checking the variable names for me. If I mistype a name, just create another one for me, pleeeease."
10. "Option Strict Off". Aka "What? Why can't I just assing this string variable to this integer variable?"
11. The hidden return variable. All functions have a hidden variable that is named with the same name as the function. Don't forget to assign to it. In any code path. If you forget, VB choses a default value for you and won't warn you.
12. BTW, there are no warnings. And this is meant to be "a productive language?"
13. REM. It'd be fun seeing a program entirely commented using exclusively REM.
14. "Array Covariance". I'm yet to know a VB programmer who can tell me what's this (BTW, I know).
15. The "Like" operator. The syntax is incompatible with the .NET Regex syntax. Answer quickly: should "x**y" match "xy" and "xay"? The answer is none. Can you explain why?
16. The "Concatenation Operator". Quoting MSDN: 'Also, there is a special case in that Nothing is treated in concatenation expressions as if it were the empty string literal ""'
17. I'm yet to find a VB programmer who can declare a char constant.
18. x!abc. Aka x("abc")
19. Copy-in/copy-out semantics when passing an argument passed to a reference parameter and the argument needs to be coerced to the right type. It sounds complicated, huh? Don't worry about, unless you're using multithreaded code.

rwestgraham wrote:
Face it. I could write an intelligent parsing algorithm to replace all the braces in your code and end up with the same programming language you so love to despise.

Actually, VB.NET -> C# converters are commercial products, so there's more to it than that. Even then, they tend to import the VisualBasic namespace and use stuff like the excrable Iif, instead of ()?: syntax. I have a major project that I won on the basis that I could convert it to C# from VB.NET. It took a half day with a commerical converter, and then hand fixing all the references to the VB namespace. I've also worked on several VB.NET web sites that had been begun by other people. These experiences confirmed what I suspected all along - the basic problem with VB is that most people who use it should not be let near a program of more than about 50 lines, they just have no idea about structure, design, or anything else. The website I worked on had stored procedures in the database, and DB calls in the middle and web tiers. Many methods were generated more than once, nothing was done efficiently, etc.

Yes, some people in VB can code, many people using C++ cannot. However, the VB people who are ignorant generally can get something that looks good enough to ship, and therein lies the danger.

The basic problem with VB.NET is that it was modified to keep the VB6 crowd happy, and that it bears the name of a 'language' whose name is beyond redemption, both because of bad design, and because of a high percentage of ignorant users.


Christian

I have several lifelong friends that are New Yorkers but I have always gravitated toward the weirdo's. - Richard Stringer
GeneralRe: Vb 6.0 Pin
rwestgraham13-Apr-05 21:05
rwestgraham13-Apr-05 21:05 
GeneralRe: Vb 6.0 Pin
Christian Graus14-Apr-05 0:10
protectorChristian Graus14-Apr-05 0:10 
GeneralRe: Vb 6.0 Pin
Dave Kreskowiak14-Apr-05 3:34
mveDave Kreskowiak14-Apr-05 3:34 
GeneralRe: Vb 6.0 Pin
Giancarlo Aguilera14-Apr-05 7:01
Giancarlo Aguilera14-Apr-05 7:01 
GeneralRe: Vb 6.0 Pin
Christian Graus14-Apr-05 12:17
protectorChristian Graus14-Apr-05 12:17 
GeneralRe: Vb 6.0 Pin
rwestgraham14-Apr-05 10:55
rwestgraham14-Apr-05 10:55 
GeneralRe: Vb 6.0 Pin
Christian Graus14-Apr-05 12:23
protectorChristian Graus14-Apr-05 12:23 
GeneralRe: Vb 6.0 Pin
rwestgraham14-Apr-05 13:41
rwestgraham14-Apr-05 13:41 
GeneralRe: Vb 6.0 Pin
Christian Graus14-Apr-05 13:55
protectorChristian Graus14-Apr-05 13:55 
GeneralRe: Vb 6.0 Pin
rwestgraham14-Apr-05 16:00
rwestgraham14-Apr-05 16:00 
GeneralExecute Autocomplete code in a ComboBoxColumn on a datagrid Pin
VBProEd13-Apr-05 6:25
VBProEd13-Apr-05 6:25 
GeneralEvents and Windows NT Pin
KreativeKai13-Apr-05 3:14
professionalKreativeKai13-Apr-05 3:14 
GeneralRe: Events and Windows NT Pin
Dave Kreskowiak13-Apr-05 3:55
mveDave Kreskowiak13-Apr-05 3:55 
GeneralRe: Events and Windows NT Pin
KreativeKai14-Apr-05 6:37
professionalKreativeKai14-Apr-05 6:37 
GeneralRe: Events and Windows NT Pin
Dave Kreskowiak14-Apr-05 6:58
mveDave Kreskowiak14-Apr-05 6:58 
GeneralRe: Events and Windows NT Pin
KreativeKai22-Apr-05 4:04
professionalKreativeKai22-Apr-05 4:04 
GeneralRe: Events and Windows NT Pin
Dave Kreskowiak23-Apr-05 2:45
mveDave Kreskowiak23-Apr-05 2:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.