Export (0) Print
Expand All
Expand Minimize
0 out of 1 rated this helpful - Rate this topic

Type.GenericTypeArguments Property

.NET Framework 4.5

Gets an array of the generic type arguments for this type.

Namespace:  System
Assembly:  mscorlib (in mscorlib.dll)
public virtual Type[] GenericTypeArguments { get; }

Property Value

Type: System.Type[]
An array of the generic type arguments for this type.

This property gets only the generic type arguments; that is, the types that have been specified for the generic type parameters of the current type. If the current type is a generic type definition, this property returns an empty array.

NoteNote

If a generic type is used in a generic method or in another generic type, some of its generic type arguments might be generic type parameters of the enclosing method or type.

To get the generic type parameters of a type that represents a generic type definition, use the TypeInfo.GenericTypeParameters property. To get a TypeInfo object for the current Type object, use the IntrospectionExtensions.GetTypeInfo extension method.

.NET Framework

Supported in: 4.5.1, 4.5

.NET for Windows Store apps

Supported in: Windows 8

.NET for Windows Phone apps

Supported in: Windows Phone 8.1, Windows Phone 8, Silverlight 8.1

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.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.