The assembly-qualified name of a type consists of the type name, including its namespace, followed by a comma, followed by the display name of the assembly. The display name of an assembly is obtained using the Assembly.FullName property.

All compilers that support the common language runtime emit the simple name of a nested class, and reflection constructs a mangled name when queried, in accordance with the following conventions.

Delimiter

Meaning

Backslash (\)

Escape character.

Comma (,)

Precedes the Assembly name.

Plus sign (+)

Precedes a nested class.

Period (.)

Denotes namespace identifiers.

Brackets ([])

After a type name, denotes an array of that type.

-or-

For a generic type, encloses the generic type argument list.

-or-

Within a type argument list, encloses an assembly-qualified type.

For example, the assembly-qualified name for a class might look like this:

If the namespace contained a plus sign, for example TopNamespace.Sub+Namespace, then the plus sign (+) would be preceded by an escape character (\) to prevent it from being interpreted as a nesting separator. Reflection would emit this string as follows:

This qualified name can be persisted and later used to load the Type. To search for and load a Type, use GetType either with the type name only or with the assembly qualified type name. GetType with the type name only will look for the Type in the caller's assembly and then in the System assembly. GetType with the assembly qualified type name will look for the Type in any assembly.

Type names may include trailing characters that denote additional information about the type, such as whether the type is a reference type, a pointer type or an array type. To retrieve the type name without these trailing characters, use t.GetElementType().ToString(), where t is the type.

Spaces are relevant in all type name components except the assembly name. In the assembly name, spaces before the ',' separator are relevant, but spaces after the ',' separator are ignored.

Generic arguments of generic types are themselves qualified by assembly name. For example, in the assembly-qualified type name for MyGenericClass<int> (MyGenericClass(Of Integer) in Visual Basic), int is expanded to the assembly-qualified type name for Int32.

If the current Type object represents a generic parameter, this property returns null.

Platform Notes

Silverlight for Windows Phone

The return value for Type.AssemblyQualifiedName is not the same between Silverlight for Windows Phone and Silverlight 4. For example, the return value for AssemblyQualifiedName on Silverlight for Windows Phone might look like this: MyType, MyAssembly, Version=1.0.0.0, Culture=neutral, PublicKeyToken=b17a5c561934e089. In , the equivalent return value might look like this: MyType, MyAssembly, Version=1.0.0.0, Culture=neutral, PublicKeyToken=B17A5C561934E089.