Thread: C++ VS Visual Basic

  1. #1
    Registered User
    Join Date
    Oct 2013
    Location
    Hellas
    Posts
    70

    C++ VS Visual Basic

    What are the advantages and disadvantages on those 2 languages? Visual Basic as I have seen is much more simpler, so why someone should learn C++?

  2. #2
    [](){}(); manasij7479's Avatar
    Join Date
    Feb 2011
    Location
    *nullptr
    Posts
    2,657
    A hammer is much more simpler to use....so why use a screwdriver?

  3. #3
    Registered User
    Join Date
    Jun 2005
    Posts
    6,815
    Quote Originally Posted by manasij7479 View Post
    A hammer is much more simpler to use....so why use a screwdriver?
    A hammer can be a very effective screwdriver ..... if you don't care too much about how well the screw holds.
    Right 98% of the time, and don't care about the other 3%.

    If I seem grumpy or unhelpful in reply to you, or tell you you need to demonstrate more effort before you can expect help, it is likely you deserve it. Suck it up, Buttercup, and read this, this, and this before posting again.

  4. #4
    Registered User
    Join Date
    Apr 2013
    Posts
    1,658
    At the companies I've worked for, some engineering coworkers use Visual Basic because the GUI design interface includes stuff like dynamic graphs, which apparently isn't included in C++ or perhaps its just harder to use. They use VB mostly as a 4th generation language, using the drag and drop design tool to create user interface stuff like dialog boxes, graphs, charts, ... , and then VB generates the code for the user interface. They then write the code that interfaces with hardware (usually via a serial port), and does the math.

    The programming type coworkers tend to use C++ and only a fraction of the programs they create need the fancy user interface stuff. The embedded code is C (not C++) with some assembly.

    The engineers also use Matlab for mathematically oriented programming and problem solving.
    Last edited by rcgldr; 10-31-2013 at 10:59 PM.

  5. #5
    Hurry Slowly vart's Avatar
    Join Date
    Oct 2006
    Location
    Rishon LeZion, Israel
    Posts
    6,788
    Quote Originally Posted by rcgldr View Post
    At the companies I've worked for, some engineering coworkers use Visual Basic because the GUI design interface includes stuff like dynamic graphs, which apparently isn't included in C++ or perhaps its just harder to use. They use VB mostly as a 4th generation language, using the drag and drop design tool to create user interface stuff like dialog boxes, graphs, charts, ... , and then VB generates the code for the user interface. They then write the code that interfaces with hardware (usually via a serial port), and does the math.
    It was a good reason in times of VB6
    Now you have C#

    VB is an easy way to get a headache - any time you need to modify the old code.
    All problems in computer science can be solved by another level of indirection,
    except for the problem of too many layers of indirection.
    – David J. Wheeler

  6. #6
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    C++ runs on anything...

    VB runs on Windows.
    Code:
    //try
    //{
    	if (a) do { f( b); } while(1);
    	else   do { f(!b); } while(1);
    //}

  7. #7
    Algorithm Dissector iMalc's Avatar
    Join Date
    Dec 2005
    Location
    New Zealand
    Posts
    6,318
    Basically VB is like riding a bike with training wheels.
    That might be fine if you're say 7 years old, but generally you wouldn't want training wheels 10-20 years later.

    "Simpler" often means "less powerful" or "slower".
    My homepage
    Advice: Take only as directed - If symptoms persist, please see your debugger

    Linus Torvalds: "But it clearly is the only right way. The fact that everybody else does it some other way only means that they are wrong"

  8. #8
    Registered User
    Join Date
    Apr 2013
    Posts
    1,658
    Quote Originally Posted by iMalc View Post
    Basically VB is like riding a bike with training wheels.
    Again, at the companies that I've worked for, the main feature than the engineers used from Visual Basic is it's graphing features implemented as part of a 4th generation language, like charts and graphs that can be dynamically updated (within reason like a few updates per second, depending on how many objects on the screen are being updated). For example a program might capture and display analytical data like error rates or signal to noise ratios from a hardware device while the user adjust's parameters to help optimize performance of a device. A lot of this stuff is early development stuff that gets archived and rarely used again once the device is optimized, so development time is the key issue, not performance of the generated programs.

  9. #9
    Master Apprentice phantomotap's Avatar
    Join Date
    Jan 2008
    Posts
    5,108
    Again, at the companies that I've worked for, the main feature than the engineers used from Visual Basic is it's graphing features implemented as part of a 4th generation language, like charts and graphs that can be dynamically updated (within reason like a few updates per second, depending on how many objects on the screen are being updated).
    O_o

    Well, "4th generation" means you are talking classic, as in not "dotNet", Visual Basic. So, yeah, that Visual Basic was like riding a bike with training wheels... only the training wheels are two different sizes and traveling over two miles an hour requires changing bikes.

    That said, sure, a lot of companies used classic Visual Basic for quick and dirty GUI covers, but even then, data driven and event driven frameworks existed for C++. These days, graphing frameworks exist that absolutely destroy Visual Basic. For some examples, you may look for protocol buffers that live over "GnuPlot". (In other words, programmable transforms with bindings available to a over a dozen languages.)

    Now, I'm not arguing with you. I know a lot companies did use Visual Basic for exactly that stuff. (I also worked at such places.) These days, you can do the heavy lifting, the GUI, the plotting, and the data transforms without leaving the comfort of single language infrastructure reducing the development time.

    Because "GnuPlot" (with dozens of bindings in C, C++, C#, PHP, Python, Ruby and others) is a thing that exists, Visual Basic for graphing is a painful exercise in "how to headache".

    Soma
    “Salem Was Wrong!” -- Pedant Necromancer
    “Four isn't random!” -- Gibbering Mouther

  10. #10
    Registered User
    Join Date
    Oct 2013
    Location
    Hellas
    Posts
    70
    Anyone knows any Visual Basic code tutorials? Because VB's coding is different from C++

  11. #11
    Registered User
    Join Date
    Apr 2013
    Posts
    1,658
    Quote Originally Posted by phantomotap View Post
    Well, "4th generation" means you are talking classic, as in not "dotNet", Visual Basic.
    True this was a while back, but the point here is that these programs were used during early development of a product, PC based tools to help analyze product or prototype performance, while the actual product (computer peripherals) used embedded code, mostly C with some assembly. Those guys still tend to used VB for that type of stuff, since it's what they are used to.

    The first "common" 4th generation language toolset I recall was Prototyper, used for older Macintosh development with the same drag and drop concept to generate the user interface and generate the code. It generated C code (maybe C++, not sure).

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Visual Studio DLL and Visual Basic
    By mathguy in forum C Programming
    Replies: 18
    Last Post: 12-08-2011, 03:55 PM
  2. Visual Basic
    By Lurker in forum A Brief History of Cprogramming.com
    Replies: 12
    Last Post: 07-29-2003, 01:09 AM
  3. Replies: 1
    Last Post: 04-20-2002, 06:49 AM
  4. Moving from Visual Basic to Visual C++
    By Unregistered in forum C++ Programming
    Replies: 3
    Last Post: 04-10-2002, 09:57 PM
  5. Visual Basic C++
    By gussguss in forum C++ Programming
    Replies: 8
    Last Post: 11-20-2001, 10:58 AM