1. Home
  2. Computing & Technology
  3. Visual Basic

CalcPad in VB.NET 2005 and VBE

By Dan Mabbutt, About.com

The procedure for building a user control in VB.NET 2005 is almost identical to 1.X. The biggest difference is that instead of right-clicking on the Toolbox and selecting Add/Remove Items, the control is added by selecting Choose Toolbox Items from the Tools menu. The rest of the process is the same. Here's the same component (actually, converted directly from VB.NET 1.1 using the Visual Studio conversion wizard) running in a form in VB.NET 2005.

--------
Click Here to display the illustration
Click the Back button on your browser to return
--------

Again, moving this control into production can be an involved process. Usually, that means installing it in the GAC, or Global Assembly Cache. You can read about the GAC in the About Visual Basic article, GACUTIL - Sharing your work in the Global Assembly Cache - A Framework Tool.

CalcPad in VB.NET 2005 Express Edition (VBE)

The code, properties, and design of a user control in VBE is the same again. But there's a twist that you have to know to create one.

Here's the twist. In VBE, create a Class Library project first and then add a User Control. You can then delete the initial class that was added automatically (usually named Class1.vb) and put all of your code and components into the user control class.

I won't show the same example in VBE because it looks (and behaves) exactly the same. In fact, I added the VB.NET 2005 DLL to my VBE Toolbox and it works great. So the free software, VBE, that you can get from Microsoft really does work well!

Next, we consider version 3!!! of CalcPad.

Explore Visual Basic
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. Visual Basic
  4. Using VB.NET
  5. User Control Components in VB.NET

©2009 About.com, a part of The New York Times Company.

All rights reserved.