This document is archived and information here might be outdated.  Recommended version.


ISubtypes.Subtypes Property (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geodatabase > ESRI.ArcGIS.GeoDatabase > Interfaces > IS > ISubtypes Interface > ISubtypes.Subtypes Property
ArcGIS Developer Help

ISubtypes.Subtypes Property

The subtypes associated with the class.

[Visual Basic .NET]
Public ReadOnly Property Subtypes As IEnumSubtype
[C#]
public IEnumSubtype Subtypes {get;}
[C++]
HRESULT get_Subtypes(
  IEnumSubtype** Subtypes
);
[C++]
Parameters
Subtypes [out, retval]

Subtypes is a parameter of type IEnumSubtype**

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

Subtypes returns a IEnumSubtype populated with all of the subtypes for the given object class.

Remarks

Every ObjectClass has a default subtype code. If the user has not explicitly specified a default subtype or a subtype field, then DefaultSubtypeCode will return a subtype code of zero. Additionally, you can query the HasSubtype property; a value of False indicates an absence of a default subtype code, True indicates the presence of a default subtype code.

If the client instead asks for the enumeration of subtypes associated with an ObjectClass and no subtype has been previously added to the ObjectClass, then the enumerator will contain a single entry with a code of zero. The subtype field index value will be �1 if a default subtype has not been previously specified. Subtypes may only be short or long integers (esriFieldTypeSmallInteger or esriFieldTypeInteger). When setting the default subtype code, if one already exists, then it will be deleted. A subtype field must have been specified prior to setting the subtype code value.

Every type of field, except for esriFieldTypeShape, may have a default value. When setting the default value (which my be assigned on a subtype basis), it will be checked against the field�s associated Domain (if one exists) for validity.

This property returns all of the subtypes for the associated object class. Subtypes returns an IEnumSubtype enumeration which you can loop through to get all of the subtypes.

[C++]

When using C++, test for an HRESULT of S_FALSE for the end of the enumeration.

See Also

ISubtypes Interface