3.7.4.1.24 RpcWinStationGetTermSrvCountersValue (Opnum 45)

The RpcWinStationGetTermSrvCountersValue method retrieves the current value of requested terminal server performance counters. The caller is not required to have any specific permission to call this method.

 BOOLEAN RpcWinStationGetTermSrvCountersValue(
   [in] SERVER_HANDLE hServer,
   [out] DWORD* pResult,
   [in, range(0, 0x1000)] DWORD dwEntries,
   [in, out, size_is(dwEntries)] PTS_COUNTER pCounter
 );

hServer: Handle to the server object. This is of type SERVER_HANDLE. The hServer argument MUST be obtained from a previous call to RpcWinStationOpenServer.

pResult:  If the call was successful, this parameter MUST be STATUS_SUCCESS (0x00000000); otherwise it MUST be an implementation-specific negative value.

dwEntries:  The number of performance counters to query. Indicates the size of the array pointed to by pCounter.

pCounter:  An array of TS_COUNTER structures. The caller MUST set the dwCounterId in the TS_COUNTER structures for each entry in the array to indicate the counter whose current value to retrieve. On return, the method MUST set the value for that performance counter. If the performance counter ID is not recognized or is not supported, it will set the bResult to 0.

Return Values:  Returns TRUE if the call succeeded, and FALSE if the method failed. On failure, pResult indicates the failure status code. Individual entries in the array pCounter will indicate whether or not the counter data for that counter could be retrieved.

Return value/code

Description

0x01

TRUE

Successful completion.

0x00

FALSE

Method call failed.