June 2006
Intermediate to advanced
1344 pages
42h 52m
English
Visual Basic allows a class declaration to span multiple source-code files. The separate portions of the class declaration in each file are known as partial classes. We have already created applications that use partial classes—in each GUI application, the code that is auto-generated by the IDE (i.e., the code that declares and creates GUI components in the code-behind file) is marked with the Partial modifier and stored in a separate source file. For example, in the GUI application in Fig. 9.2, the lines 2–3 of the auto-generated partial class (stored in FrmTimeTest.Designer.vb) are:
Partial Public Class FrmTimeTest Inherits System.Windows.Forms.Form
which indicates that the code in this file is part of class FrmTimeTest ...
Read now
Unlock full access