Talk:Visual Basic
|
Contents |
Poor Documentation
User:Enochlau: VB doesn't have poor and inaccurate documentation now, but I have heard suggestions that it did in the past. Mr. Jones 13:32, 8 Mar 2004 (UTC)
Visual Basic, Scripting Edition and for Applications
Are these the same? Or is VBA a subset of VB proper that compiles in the same way? What about the Windows Scripting Host?
Mr. Jones 21:15, 21 Feb 2004 (UTC)
No, VBScript is a mostly cut-down version of VB6 with only Variant variables. It does have the ability to define multiple classes in one file (like VB.NET) and is thus still rather powerful for algorithm and OO design.
However, VBA is VB6 or rather VB6 is VBA with a forms engine. Because Excel and Word have forms of a sort, almost any program that can be produced in VB6 can be made to be contained in a document.
Windows scripting host, and now WMI, facilitates the use of VBScript (and occasionally VB in general) for computer system administration tasks, which is the normal reason to use scripting languages in general.
Now why did you ask? ;-)
Mark Hurd 04:00, 27 Feb 2004 (UTC)
So, VBScript is interpreted as JavaScript or Python are and VB4, 5 and 6 (and .NET?) are compiled to POFF .exe files. These then call functions in DLLs, either the Forms code (VB4/5/600.dll?) or a DLL for the application (e.g. Access). OK. What about programs in (e.g. word) documents? Are they scripts or compiled binaries embeded in the OLE2 structure?
- Yes, VBScript is interpreted (though ASP caches the parsed code -- tokens -- to gain some benefit from code that isn't changing).
- Yes, VB programs are compiled to PE .exe files, however until VB5 the code was compiled to P-Code, VB5 and VB6 have a choice of P-Code or 'true' compiled code (using the C++ compiler's back-end), and VB.NET uses the .NET arhitecture which is effectively a compromise of the two, with extra features.
- Yes, there's a run-time library required for all versions:
- VBRUNx00.dll for VBx, x=1-3 (16-bit)
- VB400bb.DLL for VB4 16-bit (bb=16) or 32-bit (bb=32)
- MSVBVMx0.DLL for VBx, x=5-6 (32-bit)
- .NET Framework for VB.NET.
- VBA macros are stored as P-Code in the OLE2 structure. (P-Code means tokenized scripts.)
- Mark Hurd 15:46, 25 Jun 2004 (UTC)
I would like to talk around this a bit, because I would like to establish a clear picture of the situation.
As to what I am interested in knowing at this very moment; I wonder if it is possible to use languages other than VB in office applications (e.g. by instantiating interface objects as one does in ASP). It would seem not.
- The Office applications themselves are just ActiveX (COM) servers, so they can be manipulated with any language that can talk COM. However, the VBA IDE is tightly coupled with VBA, so you'd need an external editor.
- Mark Hurd 15:46, 25 Jun 2004 (UTC)
Many thanks for helping clear this up for me. I hope to come back and work the information you supply into the article. Mr. Jones 10:49, 5 Mar 2004 (UTC)
Removal of non-NPOV
took out the sentece, "Virtually every Microsoft product has a corresponding VB component library, which gives Microsoft a powerful lock-in on their customers." Doesn't seem neutral.
--MarXidad, 2002-01-19 9:15 pm
took this out: "One can build a simple web browser in 30 seconds flat with Visual Basic version 6, simply by following a built-in application wizard step by step." -- it seemed irrelevant. Leon
Request for information about VBDOS 1.0
This page redirects from VBDOS 1.0, but it does not seem to have any information on VBDOS. In fact, it even says VB is only for Windows, which seems in contradiction with the existence of a VBDOS 1.0. What's with that? (VBDOS 1.0 is linked from 'QBASIC programming language.') --[anonymous], 2002-12-17 3:58 pm
- I vaguely remember seeing VBDOS marketed, and that's about it. If someone knows something more about VBDOS, slap it in.
- --- williamv1138
- Done.
- --cprompt 08:05, 22 Dec 2003 (UTC)
Despair at "bad writing"
Awful, awful writing. I tried to tighten and copyedit, but died of crap writing fatigue half way through. Anyone else want a go? - David Gerard 10:49, Jan 14, 2004 (UTC)
I like the edits by 128.32.36.26, but the Evolution of VB ought to emphasise the importance of VB3 as being a stable version, the one that cause the popularity of the program to soar -- VB3 is to VB as Windows 3.1 is to Windows. I'd be bold and make the change but don't have NPOV words for it at the moment. - Mark Hurd 15:59, 25 Jun 2004 (UTC)
Does The section on VB and Hypercard belong here?
Doesn't it seem like the part on VB vs Hypercard is just out of place? I don't think it should be in there.
It was a reaction to an earlier form of the article which implied that VB was a completely original invention by Microsoft, failed to credit Alan Cooper, and failed to acknowledge any intellectual heritage for the product. Readers might have inferred that VB sprang full-grown from the head of Gates. I thought and think that a VB article needs to give some background and history. I think the absolutely essential points are:
- VB had some distinct similarities to HyperCard; HyperCard and other similar environments were "in the air" (fully-functional and available?) (Sure. HyperCard, in something (alas) very close to its final form, was introduced in 1987. VB, 1991. HyperCard was definitely available, so was Toolbook, I believe several Mac HyperCard-like products such as SuperCard had been released... Dpbsmith 16:11, 8 Mar 2004 (UTC)) at the time.
- VB was not a copy or clone of HyperCard and represented an equal or greater breakthrough. (For an example of a HyperCard knockoff or clone, I'd cite Asymmetrix Toolbook, which was at one time bundled with Windows 3.0).
These statements should be in the article somewhere, and to avoid POV needed to be more than bald assertions. In my efforts to support these statements, I got a little carried away. Dpbsmith 13:50, 8 Mar 2004 (UTC)
- I think this little historical footnote is interesting. OTOH, I don't think there's enough in it for another article. Mr. Jones 14:06, 8 Mar 2004 (UTC)
Negative POV expressed
It's my opinion that the article currently sounds pretty biased against VB. It has a list of reasons why VB is a bad language, but doesn't list advantages to it, or counter-arguments to the flaws. For instance, it says that VB doesn't use a syntax common to other languages, such as C/C++, Java, etc. But, it doesn't say that the syntax is easier for newcomers to learn, and looks more human readable to inexperienced programmers. Likewise, there's no mention of the fact that small, GUI-based applications with rather simple functionality (especially those not needing to use much API, COM models or similar) are easier built and maintaned in VB than many other languages.
Anyone else think that the article should add some positive points?
Solver 10:35, 4 Apr 2004 (UTC)
- Yes. The positive points you mentioned are attributes rather than counter-POV. Additionally, there is much evolution through the versions that is not described. Be bold. Use NPOV. -- Zigger 14:58, 2004 Apr 4 (UTC)
- Yes. Visual Basic (this is all for the talk page, of course, not for the article) is a often the target of ill-considered hostility, for several reasons. First, in the 1980s, the BASIC language itself was disparaged within the academic computer science community. Wirth had proseletized successfully for PASCAL as a better teaching language, an idea with considerable merit, but the actual adoption of PASCAL by universities led to a kind of snobbery in which instructors implied that using BASIC would rot your brain and students parrotted the sentiments. The academic community frequently disparages languages such as (in chronological order) COBOL, MUMPS, VB, etc. which are superbly designed for the real-world requirements of real-world application programmers. Second, VB is Microsoft-proprietary and attracts some scorn for that reason. Bill Gates himself, of course, together with Paul Allen, personally developed an 8080 BASIC implementation, and Microsoft corporate ego tends to push BASIC. Third, and I think you can see clear signs of this in the present market, VB knowledge became a marketable job skill in the late 1990s, with VB programmers being paid less than C++ programmers, and this intensified the snobbery (and attracted hostility from the more sophisticated programmers who perhaps saw their jobs under attack by a form of deskilling). Dpbsmith 15:10, 4 Apr 2004 (UTC)
- I agree that the article should present positive points, and I'm not going to modify it, but please would someone consider the following points (quotations from article): "Being large enough to contain functions for all common tasks without the requirement to include external libraries." - the VB runtime library which is external? And VB .NET requires the .NET framework. "Being just object oriented enough and no more. (Unfortunately this advantage has been lost in VB.NET)" - this is surely biased! "Being more visually-based than other products (e.g. some C++-based tools), requiring less hand coding" - maybe this should be changed into a general point that it is easier to program in VB. "Having a visually clear syntax (e.g. requiring special line terminator syntax to allow statements to span more than one line and thus limiting syntax errors to the line in which they occur.)" - this is also not necessarily an advantage. "Having syntax unrelated to the esoteric C-like syntax used by many other popular languages (e.g. Java, ECMAScript/JavaScript, C#, PHP, Perl, C++, C) -- this is a general advantage of BASIC-like languages." - this is clearly the opposite of the negative point mentioned earlier in the article. Maybe this point should be removed from both lists and a general point added about VB syntax, with its advantages and disadvantages together, so that it doesn't look like it was written by lots of people disagreeing about it. "Some of these advantages have been lost in later versions of VB, particularly in VB.NET, and in doing so backwards compatibility has been sacrificed." - Maybe some advantages of VB .NET should be presented as well, e.g. advantages of .NET such as ability to use .NET language interoperability, more consistent object orientation and structure, non-Microsoft versions of .NET such as Mono. Ablewisuk 16:55, 21 Jun 2004 (UTC)
- The list of advantages is just a simplistic refutation of each criticism. I'm new here, I don't know how to go about changing this but it seems that these lists should be independent from each other rather than just being a point-by-point pro/con argument. --Rhobite 17:20, Jun 30, 2004 (UTC)
I started rewriting and rearranging much of the top part of this page. The Language Features section should be expanded. As said above, the Andvatages of Visual Basic section should just be junked and re-written. Actually, we should probably rename the Disadvantages section to Controversies and talk about the disadvantages and advantages of the language. Wuzzeb 07:02, 7 Jul 2004 (UTC)
Edward G. Nilges: I read this article after visiting discussions in philosophy sites on NPOV. After reading it I am surprised to hear that NPOV is at all important to Wikipedia, because this article is a polemic against Visual Basic.
It is logically possible to write any program in VB, trivially because a Turing machine simulator can be written in VB: VB, unlike HTML, is Turing-complete. Recently I wrote and published a compiler written in VB .Net (Build Your Own .Net Language and Compiler, Apress 2004).
Where is the old view, that our job is to make a silk purse out of a sow's ear? Programmers in my day (by cracky) used to take pride in transgression, and making a tool (such as Cobol) do what it wasn't supposed to do as a minor rebellion against moronization. Why, we had to walk from the antiwar demonstration to the computer center in the snow both ways! :-), big time.
You guys ain't happy unless you have a computer in your bedroom running Linux, Python, etc.
Seriously, folks, the POV that VB is inferior is technocratic and ethnocentric, because it completely ignores the fact that for a "native" speaker of Visual Basic, his critical success factor in writing any one program is the distance from his knowledge of VB to the solution. His distance from his knowledge of C is longer if he doesn't know C. Meanwhile, the user needs a solution. Sure, use the best tool, but factor it against the real world...in which educational differentiation and racism operating within computer science "tracks" white and upper middle class students into high-class computer science programs, and the rest to DeVry, where I taught (and had to fight to get training for my students in Web technologies).
The ethnocentricity pays attention not to his training and his abilities but to the language he uses, and like Prospero in Shakespeare's Tempest, says he "gabbles like a thing demented" without being qualified to do so; for the early Elizabethan and Spanish adventurers of Shakespeare's time, on whom Shakespeare based The Tempest, did not know Carib languages...but were nonetheless authorized to judge entire peoples as Calibans.
It is true that in terms of overall programming ability, most Visual Basic specialists are inferior to C programmers. But this is not an artifact of their language; it is an artifact of their training, and the increased pressures of lower level jobs into which they are tracked.
For this reason, a truly NPOV article would have stayed clear of the issue of the "quality" of Visual Basic, reporting debates about this issue in a sidebar.
I am frankly astonished to hear claims that articles on Kant and Derrida have a POV when an honest attempt is made to bring views to life on the page, but then read this turkey on VB.
What are you guys, anyway? A bunch of Linux nerds chained to VB projects by the economy, taking out your frustrations? Come on, you can do better than this!
Neutrality ISN'T reporting the views of a dullard mass, nor is it reporting the views of people who hate Visual Basic. Neutrality is purity of heart.
New Point of View
Ok. I complelty rewrote the Advanages/Disadvantages section in an attempt to provide a neutral point of view. I personally lean more towards a critisism of Visual Basic. The VB project I work on at my job has recently upgraded to VB.NET, and I like VB.NET more than Visual Basic. So someone pro Visual Basic should read this article and correct any of my mistakes :) Wuzzeb 20:36, 10 Jul 2004 (UTC)
String handling, other capabilities of VB
I've been using VB for many years now and even I'll admit that string handling is not its strong point. That statement is simply wrong, and I've removed it. VB6 has very weak string handling functions when compared to other modern high-level languages. Likewise, it's almost universally acknowledged that VB6 has poor math performance. I also removed these POV statements: "By some puritanical standards," "superfluous line termination characters," "according to some programmers unfamilar with its strengths." Rhobite 22:19, Aug 31, 2004 (UTC)
Bias in this article
Here are some word counts:
C Programming Language
controversial 0 harmful 0 poor 0 too 5 less 0 critic 0 criticisms 0 unintelligible 0 incomplete 0
Pascal Programming Language
controversial 0 harmful 1 poor 0 too 0 less 1 critic 4 criticisms 1 unintelligible 0 incomplete 0
Visual Basic
controversial 2 harmful 1 poor 1 too 5 less 1 critic 8 criticisms 3 unintelligible 1 incomplete 1
I say this article is mostly POV. Every time a benefit of VB is entered, it is nullified by virtue of it being VB and/or Microsoft! We do not go into C or Pascal limitations, shooting down the relative pains of semicolons, null termination, array bounds errors, and constant must-compile-first limitations which are commonplace. There are weakness of every language, VB is no exception. But this article has just become firing squad against Microsoft. Nice. DanP 15:19, 1 Sep 2004 (UTC)
- There are plenty of criticisms of C, I recommend adding those to C programming language rather than whitewashing VB. In any case, please don't add false information to VB. Nobody thinks VB6 is ideal for string handling, for example. Rhobite 16:18, Sep 1, 2004 (UTC)
- Whitewashing is not the goal. Neutrality is better here. I haven't found anything better for string handling, and I am not nobody, as you say. I did not mean to say VB was absolutely ideal, only that it is better than average. Doesn't that merit even a mention? The BStr objects integrated into VB are pretty speedy and adaptable to different memory models, parameter passing, pattern matching, and a few other things that work pretty well. They are not the fastest, and they are not the most robust, but they balance both reasonably well. I hope you can agree. DanP 19:09, 2 Sep 2004 (UTC)
- In the article you said that case insensitive comparison is a unique and ideal feature of VB, but this is a common feature available in every one of VB's competitors. I also don't know what built-in functions are uniquely adapted for string handling, as you say. VB has very rudimentary string support: instr family, len, replace, lcase/ucase, trim family, strcomp, join/split, and the VBScript regex library. This is all very standard stuff, available in just about every high level modern language. To name some examples of string functions lacking in VB: You can't insert one string inside another without multiple concatenations. Regular expressions have to be done through the VBScript library. Concatenations are often slow. Rhobite 19:57, Sep 2, 2004 (UTC)
- A lot of the bias against VB is not anti-Microsoft bias, but anti-BASIC bias. (Although the two are somewhat tied together, because of Bill Gates' personal involvement in the development of early versions of BASIC for the 8080). In the mid-seventies, several trends collided. First, Dartmouth innovated the idea that all students should know how to use computers. This resulted both in a) widespread familiarization with BASIC and b) association of BASIC with non-programmers. Dartmouth BASIC was a nice, simple, practical, impure language that embodied one kind of teaching goal. The early microcomputer movement grew up completely outside the professional mainstream, and the people who developed hobby computers knew BASIC and implemented it.
- Meanwhile, Wirth and others approached the subject of "a teaching language" with a different agenda. They had their own concepts of what the proper approach to programming was, and its heritage was academic computer science in general and ALGOL in particular.
- BASIC was, in fact, regarded by its creators as a simplified version of FORTRAN--just as hard to believe as Volapuk being based on English, but true--while Pascal was a simplified (and improved) version of ALGOL.
- Well, there was an enormous amount of snobbery displayed, which basically persists to this day, between the two languages. Pascal was associated with the academic mainstream, BASIC with the hoi polloi. I don't remember exactly what Wirth really said, but it soon became corrupted by instructors and by arrogant young students who were proud of being in Pascal classes into something like "BASIC rots your mind."
- Bill Gates, because of ego issues, was having none of that and Microsoft has always used versions of BASIC in its flagship products.
- All of this is amazingly independent of the actual strengths and weaknesses of the two languages.
- C sprung up in the late 1970s and carried different load of snobbish baggage with it. In particular, whereever there is a tradeoff between performance and safety, C/C++ opt for performance. Of course, if you are an imperfect mortal, the chances that your C program has serious bugs in it are higher than if you programmed in a safer language, but what macho programmer will admit to being imperfect?
- Now, as for VB having good string handling... sorry, that's not true. It only has good string handling in comparison to languages which don't really have strings in them as fundamental data types at all. That does happen to include quite a few languages, including C and C++. However, VB's string operations are very weak compared to SNOBOL or MUMPS, to pick two other languages at random. [[User:Dpbsmith|Dpbsmith (talk)]] 20:10, 2 Sep 2004 (UTC)
Again I am reverting some of your edits, DanP. Explanations:
Saying VB is controversial according to critics is redundant. If there are critics, there is controversy. Do you really think VB is not controversial?
Rephrased some other stuff that was redundant, such as the database paragraph, which I like btw.
re: "poor mathematical performance." I am reasonably sure this is the case. I added a dubious tag and I will remove it once I add a reference showing that VB6 does in fact have poor math performance.
I also want to note that I find your edits sloppy and haphazard. Please make sure your tenses and capitalization agree, and that your headings match their contents. For instance, removing the text "VB is criticized for" makes the list that follows it confusing. Rhobite 21:43, Sep 9, 2004 (UTC)
- Some of that is your POV. Removing the text "VB is criticized for" is NPOV. You cannot leave that in there while some feel those very criticisms are precisely some of VB's strengths. That is POV. It is clearly a value judgement which ought to require changing to "VB is sometimes criticized for, but sometimes praised for", which seems quite lengthy and frivolous to me.
- I apologize for capitalization mishaps. I will try better next time. Much of the poor math performance that is complained about is often simply a misunderstanding of the compiler options. You cannot compare C++, or some math-optimized language with VB, while leaving out the fact that VB sets, by default, its math performance to the slower compiler options. Correctly used compiler options using floating point math yield rapid enough performance, outpacing all but a handful of other languages with similar feature sets. That is my experience anyway, so please don't leave a blanket "poor math performance" without some qualification as to what performance and who is making that judgement. See weasel words.
- Outside of academia and some hacker code puritans, VB is not so overwhelmingly controversial. It is a language like any other, and it is just one package available. This whole article zooms in on controversy like it is the sole reason for VB's existance, and perhaps that doesn't need to be repeated over and over. I'm not defending VB at all, but just saying it does not merit a slanted POV. DanP 14:45, 10 Sep 2004 (UTC)
Dan, if you can honestly say that array bases have never confused you in VB, I question your level of experience with the language. Rhobite 22:56, Sep 10, 2004 (UTC)
- Not quite as much as outside VB. The constant juggling +1 and -1 to force everything to zero lower bound is commonplace in some languages. VB seems to reduce this problem, though I'm not saying I prefer it. I'm only saying some algorithms are simplified. DanP 14:13, 17 Sep 2004 (UTC)
- This is an issue with the BASIC language itself, not with VB. At least I think that's right; AFAIK the "OPTION BASE" statement is part of ANSI BASIC and common in BASIC dialects since the early eighties.
- I wonder if it's asking too much to ask people to try to separate issues that pertain to VB from issues that pertain to BASIC itself? Once you've criticized Microsoft for deciding to make VB a dialect of BASIC, there's no need to go on and on criticizing Microsoft point-by-point for every individual disagreeable characteristic of BASIC.
- Here's an interesting reference: Based arrays (http://www.mvps.org/vb/hardcore/html/optionbasezero-basedarrays.htm)
- Actually, ALGOL, ADA and Pascal all allow individual arrays to start at any base, so to my way of thinking it's a deficiency in C that you are forced to use zero-based arrays exclusively. [[User:Dpbsmith|Dpbsmith (talk)]] 18:33, 17 Sep 2004 (UTC)
BASIC and "mental mutilation" of programmers
I said above that Wirth said something that soon became corrupted by instructors and by arrogant young students who were proud of being in Pascal classes into something like "BASIC rots your mind." I was wrong in attributing this to Wirth. The BASIC programming language has a link to the source [1] (http://www.cs.virginia.edu/~evans/cs655/readings/ewd498.html), which was Edgsger Dijkstra in 1975, and the actual passage in question is (in part):
- FORTRAN—"the infantile disorder"—by now nearly 20 years old, is hopelessly inadequate for whatever computer application you have in mind today: it is now too clumsy, too risky, and too expensive to use.
- PL/I —"the fatal disease"—belongs more to the problem set than to the solution set.
- It is practically impossible to teach good programming to students that have had a prior exposure to BASIC: as potential programmers they are mentally mutilated beyond hope of regeneration.
- The use of COBOL cripples the mind; its teaching should, therefore, be regarded as a criminal offence.
- APL is a mistake, carried through to perfection. It is the language of the future for the programming techniques of the past: it creates a new generation of coding bums.
So, actually, Dijkstra's language was quite strong, but the criticism was being applied to virtually all of the most popular languages of the day. [[User:Dpbsmith|Dpbsmith (talk)]] 18:44, 17 Sep 2004 (UTC)
Link to "banker's method"
The article linked by "banker's method" doesn't mention said method. Something needs to be fixed but I'm not sure what. Deco 03:22, 30 Dec 2004 (UTC)
- Fixed. The original significant figures page had significance arithmetic split from it last month. Mark Hurd 16:05, 5 Jan 2005 (UTC)