1 #ifndef _LMUSE_H 2 #define _LMUSE_H 3 4 #ifdef __cplusplus 5 extern "C" { 6 #endif 7 #include <lmuseflg.h> 8 #define USE_LOCAL_PARMNUM 1 9 #define USE_REMOTE_PARMNUM 2 10 #define USE_PASSWORD_PARMNUM 3 11 #define USE_ASGTYPE_PARMNUM 4 12 #define USE_USERNAME_PARMNUM 5 13 #define USE_DOMAINNAME_PARMNUM 6 14 #define USE_OK 0 15 #define USE_PAUSED 1 16 #define USE_SESSLOST 2 17 #define USE_DISCONN 2 18 #define USE_NETERR 3 19 #define USE_CONN 4 20 #define USE_RECONN 5 21 #define USE_WILDCARD ((DWORD)-1) 22 #define USE_DISKDEV 0 23 #define USE_SPOOLDEV 1 24 #define USE_CHARDEV 2 25 #define USE_IPC 3 26 typedef struct _USE_INFO_0 { 27 LPWSTR ui0_local; 28 LPWSTR ui0_remote; 29 }USE_INFO_0,*PUSE_INFO_0,*LPUSE_INFO_0; 30 typedef struct _USE_INFO_1 { 31 LPWSTR ui1_local; 32 LPWSTR ui1_remote; 33 LPWSTR ui1_password; 34 DWORD ui1_status; 35 DWORD ui1_asg_type; 36 DWORD ui1_refcount; 37 DWORD ui1_usecount; 38 }USE_INFO_1,*PUSE_INFO_1,*LPUSE_INFO_1; 39 typedef struct _USE_INFO_2 { 40 LPWSTR ui2_local; 41 LPWSTR ui2_remote; 42 LPWSTR ui2_password; 43 DWORD ui2_status; 44 DWORD ui2_asg_type; 45 DWORD ui2_refcount; 46 DWORD ui2_usecount; 47 LPWSTR ui2_username; 48 LPWSTR ui2_domainname; 49 }USE_INFO_2,*PUSE_INFO_2,*LPUSE_INFO_2; 50 NET_API_STATUS WINAPI NetUseAdd(LPWSTR,DWORD,PBYTE,PDWORD); 51 NET_API_STATUS WINAPI NetUseDel(LPWSTR,LPWSTR,DWORD); 52 NET_API_STATUS WINAPI NetUseEnum(LPWSTR,DWORD,PBYTE*,DWORD,PDWORD,PDWORD,PDWORD); 53 NET_API_STATUS WINAPI NetUseGetInfo(LPWSTR,LPWSTR,DWORD,PBYTE*); 54 #ifdef __cplusplus 55 } 56 #endif 57 #endif 58