TypeName Property
Collapse the table of content
Expand the table of content

TypeLoadException.TypeName Property

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Gets the fully qualified name of the type that causes the exception.

Namespace:  System
Assembly:  mscorlib (in mscorlib.dll)

public string TypeName { get; }

Property Value

Type: System.String
The fully qualified type name.

Notes to Inheritors

When overriding TypeName in a derived class, be sure to call the base class's TypeName property.

This property is read-only.

The following example attempts to load a non-existent type from the mscorlib assembly. The resulting exception is caught, and the TypeName and Message values are displayed. For this code example to run, you must provide the fully qualified assembly name.

Windows Phone OS

Supported in: 8.1, 8.0

Show:
© 2017 Microsoft