NetStatisticsGet2

NetStatisticsGet2 retrieves operating statistics for a service. Currently, only the Workstation and Server services are supported.

Security Requirements

Only members of the Administrators or Account Operators local group can successfully execute NetStatisticsGet2 on a remote server.

NET_API_STATUS NetStatisticsGet2(

LPTSTR server,  
LPTSTR service,  
DWORD level,  
DWORD options,  
LPBYTE *bufptr  
);  

Parameters

server

Pointer to a Unicode string that contains the name of the server on which to execute NetStatisticsGet2. A NULL pointer or null string specifies the local computer.

service

Pointer to a Unicode string that contains the name of the service about which to get the statistics. Only the values SERVER and WORKSTATION are currently allowed.

level

Specifies the following value to return the level of information provided.

Value Meaning
0 The bufptr parameter points to an array of STAT_WORKSTATION_0 or STAT_SERVER_0 structures.

options

Must be zero.

bufptr

Pointer to the buffer in which the data set with the level parameter is stored.

See Also

NetServerGetInfo, STAT_SERVER_0, STAT_WORKSTATION_0