Share via


IDebugProperty3::GetCustomViewerCount

Gets the number of custom viewers that might be available for this property.

HRESULT GetCustomViewerCount(
   ULONG* pcelt
);
int GetCustomViewerCount(
   out uint pcelt
);

Parameters

  • pcelt
    [out] The number of custom viewers available for this property.

Return Value

If successful, returns S_OK; otherwise, returns an error code.

Remarks

In order to support type visualizers, this method forwards the call to the IEEVisualizerService::GetCustomViewerCount method. If the expression evaluator also supports custom viewers for this property's type, this method adds the number of custom viewers to the returned value.

For detailed information about the differences between type visualizers and custom viewers, see Type Visualizer and Custom Viewer.

Example

The following example shows how to implement this method for a CProperty object that exposes the IDebugProperty3 interface.

STDMETHODIMP CProperty::GetCustomViewerCount(ULONG* pcelt)
{
    if (pcelt == NULL)
    {
        return E_POINTER;
    }

    if (GetVisualizerService())
    {
        return m_pIEEVisualizerService->GetCustomViewerCount(pcelt);
    }
    else
    {
        return E_NOTIMPL;
    }
}

See Also

Reference

IDebugProperty3

IEEVisualizerService::GetCustomViewerCount

Concepts

Type Visualizer and Custom Viewer