CounterPathCallBack callback function (pdh.h)

Applications implement the CounterPathCallBack function to process the counter path strings returned by the Browse dialog box.

Syntax

CounterPathCallBack Counterpathcallback;

PDH_STATUS Counterpathcallback(
  DWORD_PTR unnamedParam1
)
{...}

Parameters

unnamedParam1

User-defined value passed to the callback function by the Browse dialog box. You set this value in the dwCallBackArg member of the PDH_BROWSE_DLG_CONFIG structure.

Return value

Return ERROR_SUCCESS if the function succeeds.

If the function fails due to a transient error, you can return PDH_RETRY and PDH will call your callback immediately.

Otherwise, return an appropriate error code. The error code is passed back to the caller of PdhBrowseCounters.

Remarks

The following members of the PDH_BROWSE_DLG_CONFIG structure are used to communicate with the callback function:

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header pdh.h

See also

PDH_BROWSE_DLG_CONFIG

PdhBrowseCounters