Should You Use Visual Basic .NET?


A Visual Basic programmer’s joke asks, “What’s the difference between Visual Basic .NET and C#? About three months!” The implication is that Visual Basic .NET syntax is easier to understand, and building applications with it is faster. Similarly, C# programmers have their jokes about Visual Basic .NET, implying that C# is more powerful.

In fact, Visual Basic .NET is not a whole lot easier to use than C#, and C# is not significantly more powerful. The basic form of the two languages is very similar. Aside from a few stylistic differences (Visual Basic is line-oriented; C# uses lots of braces and semicolons), the languages are comparable. Both use the Visual Studio development environment, both provide access to the .NET Framework of support classes and tools, and both provide similar syntax for performing basic programming tasks.

In fact, the languages are so similar that many of Microsoft’s web pages lump the two together. For example, the page http://msdn.microsoft.com/library/en-us/vbcon/html/vboriWhatsNewVB70.asp is titled “What’s New in Visual Basic and Visual C#.”

The main difference between these languages is one of style. If you have experience with previous versions of Visual Basic, you will probably find Visual Basic .NET easier to get used to. If you have experience with C++ or Java, you will probably find C# (or Visual C++ or Visual J#) easy to learn.

Visual Basic does have some ties with other Microsoft products. For example, Active Server Pages (ASP) uses Visual Basic to create interactive web pages. Microsoft Office applications (Word, Excel, PowerPoint, and so forth) and many third-party tools use Visual Basic for Applications (VBA) as a macro programming language. If you know Visual Basic, you have a head start in using these other languages. ASP and VBA are based on pre-.NET versions of Visual Basic, so you won’t instantly know how to use them, but you’ll have a big advantage if you need to learn ASP or VBA.

If you are new to programming, either Visual Basic .NET or C# is a good choice. I think Visual Basic .NET may be a little easier to learn, but I may be slightly biased because I’ve been using Visual Basic lately. You won’t be making a big mistake either way, and you can easily switch later. Of course, if you have already bought this book, you should stick with Visual Basic to get the most benefit.




Visual Basic 2005 with  .NET 3.0 Programmer's Reference
Visual Basic 2005 with .NET 3.0 Programmer's Reference
ISBN: 470137053
EAN: N/A
Year: 2007
Pages: 417

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net