SyntaxPartial Class className [statements] End Class or: Partial Structure structureName [statements] End Structure These two syntax examples show only the minimal grammar for the Class and Structure statements, for demonstration of the Partial keyword only. DescriptionThe Partial keyword allows a single class or structure definition to be divided into multiple source code files. At least one of the class or structure portions must include the Partial keyword. For syntax details on using the Partial keyword in context, see the Class...End Class Statement and the Structure...End Structure Statement entries elsewhere in this chapter. ExampleThis example shows a class divided into two distinct files. The first source code file includes the following code. Public Class Customer ...statements... End Class The second source code file includes this code. Public Partial Class Customer ...more statements... End Class If desired, the Partial keyword could be added to both class component definitions. Version DifferencesThe Partial keyword was introduced with Visual Basic 2005. See AlsoClass...End Class Statement, Structure...End Structure Statement |