| title | ms.date | ms.prod | ms.technology | ms.topic | f1_keywords | dev_langs | helpviewer_keywords | ms.assetid | caps.latest.revision | author | ms.author | translation.priority.ht | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
partial (Type) (C# Reference) |
2015-07-20 |
.net |
|
article |
|
|
|
27320743-a22e-4c7b-b0b3-53afe3607334 |
24 |
BillWagner |
wiwagn |
|
partial (Type) (C# Reference)
Partial type definitions allow for the definition of a class, struct, or interface to be split into multiple files.
In File1.cs:
[!code-cscsrefKeywordsContextual#3]
In File2.cs the declaration:
[!code-cscsrefKeywordsContextual#4]
Remarks
Splitting a class, struct or interface type over several files can be useful when you are working with large projects, or with automatically generated code such as that provided by the Windows Forms Designer. A partial type may contain a partial method. For more information, see Partial Classes and Methods.
C# Language Specification
[!INCLUDECSharplangspec]
See Also
C# Reference
C# Programming Guide
Modifiers
Introduction to Generics