NetworkEnumConnection enumerates connections the user of the workstation has made.
#include <nwiapi.h>
PSZ NetworkName;
ULONG flType;
ULONG ulLevel;
PVOID pBuf;
ULONG cbBuf;
PULONG pcReturned;
PULONG pcTotal;
PULONG pcbNeeded;
PVOID pReserved;
ULONG ulreturns; /*
A network driver is not limited to just these errors . Network drivers will return the following errors when they occur , but other error numbers can be returned for errors not listed . * /
ulreturns = NetworkEnumConnection ( NetworkName ,
flType , ulLevel , pBuf , cbBuf ,
pcReturned , pcTotal , pcbNeeded ,
pReserved ) ;