Gets the type from which the current Type directly inherits.
Assembly: mscorlib (in mscorlib.dll)
Interfaces inherit from zero or more base interfaces; therefore, this property returns nullptr if the Type object represents an interface. The base interfaces can be determined with GetInterfaces or FindInterfaces.
If the current Type represents a constructed generic type, the base type reflects the generic arguments. For example, consider the following declarations:
For the constructed type C<int> (C(Of Integer) in Visual Basic), the property returns B<int>.
If the current Type represents a type parameter of a generic type definition, returns the class constraint, that is, the class the type parameter must inherit. If there is no class constraint, returns System::Object.
This property is read-only.
The following example demonstrates using the property.
The following example uses recursion to list the complete inheritance hierarchy of each class found in an assembly. The example defines a class named C that derives from a class named B, which, in turn, derives from a class named A.
Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.