Determining Whether a Counter Is Located on a Computer
To determine if a counter is installed on a particular computer, call PdhValidatePath with the fully qualified counter path. The function returns ERROR_SUCCESS if the counter is located on the specified computer.
PdhValidatePath validates the entire path; therefore, if any object, instance, or counter in the path does not exist, the return value indicates so. PdhValidatePath verifies the specified counter path in this order: computer, performance object, instance, and counter.