In this presentation you will see how to create a simple class library using Visual Basic. Class library is a re-usable collection, or a component, of classes and operations, which serve some common purpose that different applications can use. In this example we create a class library containing a class called MyServer, which has a method called Calculate. This method calculates two integer operands by using the given operator (+, -, /, *). So, the operands and the operator are the parameters of the method. There is also a code listing in a separate file (PDF) where you can see the complete code of the class and write it into your class. Later we will create a few client applications, which use this class library to perform calculations. Note that the compiled version of the library will have a file extension .dll. This example applies also to Visual C# and Visual J#.
Presentation type: Flash SWF
Software needed to apply: Microsoft Visual Studio 2005
Open the presentation here.
Separate code listings can be found here (you can open them while the presentation, too).
No comments:
Post a Comment