5 ms·
Why on earth would you use VB.Net for something new?
by radicalbyte 9y ago
Why on earth would you use VB.Net for something new?
- quincunx 9y agoTo just get it done? To win dirty? To just ship it? Why would a carpenter have to learn masonry to build a house? Because it makes for a better house? He might never make the house, better to build it out of wood.
- mathgeek 9y agoBecause you use the tool you know best.
- graycat 9y agoWhy not? From VB.NET, can call the original .NET Framework, e.g., 4.0, 4.5, whatever, including ASP.NET and ADO.NET. Side issue: Just what the .NET Core is and/or its pros/cons I don't know. Microsoft's documentation seems to assume I already know what the Core is and why I'd want it. Not the first time Microsoft didn't do well explaining their work. Microsoft: I don't have even as much as a weak little hollow hint of a tiny clue what the heck the .NET Core is or why I would or would not want it; the times I tried to find out were all self-inflicted tooth drilling; I likely don't need the Core or have to care about it so gave up trying to find out. Next, on Windows, AFAIK, the main alternative to VB.NET would be just C#. My understanding is that VB.NET and C# differ mostly only in their particular flavors of syntactic sugar and that there is a translator from one to the other, maybe from VB.NET to C#. The flavor of C# was borrowed from C, and I don't like it. Back to K&R, the C syntax was deliberately absurdly sparse and idiosyncratic. I wrote some C code; I mowed grass in 103 F; I shoveled snow in 0 F; I didn't like any of those three. The VB.NET syntax is closer to traditional for Pascal, PL/I, Fortran, and Algol. Compared with C#, IMHO VB.NET is easier to read, write, teach, and learn and less prone to errors from obscure syntax. With VB.NET I get (A) objects, (B) strings, (C) memory management ("Look, Ma, no memory leaks!"), (D) good enough exceptional condition handling, (E) platform invoke for calling, say, C, (F) fast compiling with good error messages and so far no bugs encountered, (G) reasonably good documentation, (H) ability to have subroutines and functions and some scope of names functionality, (I) the usual Do While and If-Then-Else, (J) the math functions and some good time and date handling functions,(K) easy comment syntax, .... Looks fine to me. I'd like more on scope of names, e.g., as in PL/I. Maybe a pre-processor, e.g., again as in PL/I, would be nice. At times longer precision arithmetic would be nice; I don't know what the latest x86 has in hardware. And I can think of some things new to programming languages that would be nice. But I can't complain: VB.NET has let me write my 24,000 statements in 100,000 lines of typing (just from my favorite editor KEdit and a lot of macros but no use of an IDE). So, with the 100,000 lines for 24,000 statements, there is a lot of internal documentation. I had no trouble debugging the code. I wrote no prototype code, and my code doesn't need refactoring. The code looks fine for quite significant production. For ASP.NET and IIS, maybe I could gripe: First, I didn't like their approaches to Web user session state. So, I wrote my own Web Session State Server, just TCP/IP socket communications with de/serialization, and two instances of their main collection class -- darned fast and easy enough to scale just via sharding, even without Web user session affinity. For the input queue, I just used the TCP/IP FIFO; the queue depth permitted should be deep enough. For a Web site log server, again I don't like what Microsoft has so, as soon as I rebuild the main boot partition on my development computer from a disaster, I'll take the Web Session State Store, rip out the use of the collection class, put in a file write statement, and, presto, bingo, get a Web site log server. In total the work had a lot of mud wrestling and fighting unexpected problems. But the work that was uniquely mine and at all predictable was all fast, fun, and easy.
- rsynnott 9y agoI didn’t know it was even a thing; haven’t heard anything about it in around ten years.
- graycat 9y agoVisual Basic .NET is not much like the Visual Basic of 10 years ago. As far as I can tell, Visual Basic .NET is now essentially as powerful as C# or any other Microsoft language on Windows. Supposedly C# has lambda expressions. Okay. If I need those, maybe I'll write some C#. But have VB.NET call or be called by C# is relatively easy. So, I could have a function in C# called by my main code in VB.NET. I wrote enough C to understand it fairly well, at least at the level in K&R. I've looked at some C# code, and it seems to read easily enough. Maybe I could be writing C# in a few days. If I want to convert to C#, I understand that there is a translator to do that for me. I do like the more traditional syntax of VB.NET instead of the deliberately "idiosyncratic" syntax of C borrowed by C#. So, I see no biggie reason not to use the syntax I prefer in VB.NET. I learned programming long before C++ or even C. I skipped C++ -- never wrote a line of it. My first code with objects was essentially VB.NET. The objects are easy enough, close enough to what I did with structures in PL/I. Now with .NET, VB.NET, and C#, there's reduced reason to write C++ on Windows. There are plenty of serious criticisms of C++ for important production software. Yup, it's possible to write good code for big projects in C++, but just from memory management I'll let VB.NET handle that for me.
- ShabbosGoy 9y agoGood luck with your project! This was a fun read. Don't let the haters keep you down, just remember Zuckerberg shipped Facebook in PHP.
- graycat 9y agoYes, supposedly the first version of Google was something equally weak! Apparently since then Google has written a huge volume of some really good code. Good for Google.