ICorDebugType2::GetTypeID Method

Gets a COR_TYPEID for this type.


    ([out] COR_TYPEID *id  


[out] A pointer to the COR_TYPEID for this ICorDebugType.

Return Value

The return value is S_OK on success, or a failure HRESULT code on failure. The HRESULT codes include the following:

Return code Description
S_OK Method succeeded. The method has retrieved a valid COR_TYPEID.
CORDBG_E_CLASS_NOT_LOADED The type has not been loaded.
CORDBG_E_UNSUPPORTED The type is not supported.


This method provides a mapping from the ICorDebugType, which represents a type that may or may not have been loaded into the runtime, to a COR_TYPEID, which serves as an opaque handle that identifies a type loaded into the runtime.

When the type that the ICorDebugType represents has not yet been loaded, this method returns CORDBG_E_CLASS_NOT_LOADED. If the type is not supported, it returns CORDBG_E_UNSUPPORTED.


Platforms: See System Requirements.

Header: CorDebug.idl, CorDebug.h

Library: CorGuids.lib

.NET Framework Versions: Available since 4.6.2

See also