oreilly.comSafari Books Online.Conferences.


AddThis Social Bookmark Button

Top Five Visual Basic .NET Tips

by Dave Grundgeiger, author of Programming Visual Basic .NET

The .NET Framework and Visual Basic .NET represent a huge departure from the Visual Basic 6 programming environment. Some developers may see this as daunting, but I see it as exciting. The changes that Microsoft has made to Visual Basic have been made for the sole purpose of making it a better tool for writing professional applications in the coming years. I think they have succeeded. Every time that I dig down to find out how "X" is done in .NET, I'm always pleasantly surprised by the simplicity and elegance of the solution. I think you will be too. Here are my top five tips on how to get comfortable with Visual Basic .NET.

1. Spend time with the .NET Framework classes

The hard part about moving up to Visual Basic .NET is not the language, but learning to use the types provided in the .NET Framework class library. The class library wraps all of the functionality provided by the Windows operating system and the .NET common language runtime. It provides types for creating GUI applications, Web apps, and Web services. It provides code for accessing data in SQL Server and other database, code for working with regular expressions and XML, code for low-level network access, and so on. In fact, there are about 4,000 types defined in the .NET Framework class library. The good news is that all .NET languages access the .NET Framework class library in the same way, meaning that once you've mastered the class library, you can move from language to language with relative ease.

So, how do you master the .NET Framework class library? Start with a good class browser. All .NET types are self-describing, and a number of .NET enthusiasts have written applications for browsing type information. There is a very good one available called Reflector, written by Lutz Roeder at Microsoft, which can be downloaded for free from his Programming .NET Web site.

Related Reading

Programming Visual Basic .NETProgramming Visual Basic .NET
By Dave Grundgeiger
Table of Contents
Sample Chapter
Full Description

With Reflector you can:

  • Browse the assemblies, modules, types, and type members found in the .NET Framework class library
  • Browse your own or third-party assemblies
  • Reverse-engineer declarations in either Visual Basic .NET or C# (and potentially other languages as new plug-ins become available)
  • View any method's disassembled IL, as long as the method wasn't written directly in native code. (IL is the compiled code of any .NET application.)

In addition, there are plans for adding the ability to reverse-engineer source code in C#.

Another great tool is Anakrino, written by Jay Freeman. It too can be downloaded for free. In addition to being able to browse Microsoft and third-party assemblies and show disassembled IL, Anakrino can actually decompile IL code into C# code. That is, it generates C# code that, if compiled, would produce the IL that was fed to it (regardless of the language in which the component was originally written). Unfortunately, at the time of this writing, there are no plans to add a Visual Basic .NET decompiler to the product.

2. Use the Web

You are not alone! There is an amazing amount of brainpower floating around in cyberspace. If you are stuck, you need never stay stuck for long. Here are some of my favorite hangouts on the Web.

.NET Information

This is the official home page for information about Microsoft's .NET initiative. On this page you will find links to:
  • Definitions and overviews of .NET
  • Information about .NET My Services, Microsoft's package of Web-service offerings
  • .NET books and articles
  • .NET training
  • Information about Visual Studio .NET
  • .NET success stories
Microsoft Developer Network (MSDN)
This offers complete .NET reference documentation online.
Microsoft's GotDotNet
.NET articles, samples, and links are provided by Microsoft .NET team members, as well as users.
Microsoft's IBuySpy
This is a reference implementation for a complete Web site developed using ASP .NET. Complete source code is downloadable in Visual Basic .NET or C#.
O'Reilly has a large lineup of .NET books written by experts in the field.
Ron's VB Forum
O'Reilly editor Ron Petrusha hosts this column in which particularly interesting VB questions are answered.
DevX .NET Developer Resources
This is a great list of links to a huge number of .NET resources.

Discussion Lists

Discussion lists are one of the greatest resources on the Internet. These give you the opportunity to ask questions of tens, hundreds, or thousands of people who are in your field of interest. The Web URLs listed here link to pages that provide instructions for subscribing to the lists.


If you've never before been a member of a discussion list, take care to note the concept of netiquette. This term refers to the rules of behavior expected from people who post messages to discussion lists. You will receive or be directed to a list of such expectations when you subscribe to a list, but they can be summed up as follows:

  1. Monitor the discussion list a while before posting messages.
  2. If available, search the list archives before posting a question.
  3. Don't post questions that are outside of the list's discussion topic.
  4. Be nice.
  5. Answer the questions that you can.
  6. Maximize your signal-to-noise ratio. (That means you should post more helpful answers than witty remarks.)
DevelopMentor's DOTNET List
This is my all-time favorite .NET hangout. There are many heavy hitters on this list, including Microsoft development team members and program managers as well as third-party experts who were learning and using .NET as much as a year or two before it's official release.
ASP Lists
This site is amazing for its breadth of coverage. There are over 400 highly focused, moderated lists available through this one site. Many of these are now .NET-related, and many are available in languages other than English.
Visual Basic List
The members of this list discuss everything related to Visual Basic, including Visual Basic .NET and earlier versions. This is a large, very active list with developers of all skill levels. There are plenty of advanced Visual Basic developers on this list who are ready to lend a hand when they can. There are approximately 4,400 subscribers.

Comment on this articleDo you have VB .NET tips of your own?
Post your comments
Visual Basic Beginner's List
For beginners who don't feel comfortable posting to the Visual Basic List, there is the Visual Basic Beginner's List. There are approximately 1,000 subscribers.

In addition to these resources, consider joining (or starting!) a local .NET developers group.

Pages: 1, 2

Next Pagearrow