USE_INFO_1

The USE_INFO_1 structure contains status information about a remote or shared resource and their associated accounts.

typedef struct _USE_INFO_1 {
    LPTSTR  ui1_local;
    LPTSTR  ui1_remote;
    LPTSTR  ui1_password;
    DWORD   ui1_status;
    DWORD   ui1_asg_type;
    DWORD   ui1_refcount;
    DWORD   ui1_usecount;
}USE_INFO_1, *PUSE_INFO_1, *LPUSE_INFO_1;
 

Members

ui1_local
Specifies a Unicode string that contains the local device name (for example, drive E or LPT1) being redirected to the shared resource. The constant DEVLEN specifies the maximum number of characters in the string.
ui1_remote
Points to a Unicode string that specifies the share name of the remote resource. The string is in the form
\e\eservername\e\esharename
 
ui1_password
Points to a Unicode string that contains the password needed to establish a session with a specific workstation.
ui1_status
Specifies the status of the connection. This element is not used by the NetUseAdd function. The following values are defined:
Value Meaning
USE_OK The connection is valid.
USE_PAUSED Paused by local workstation.
USE_SESSLOST Disconnected.
USE_DISCONN An error occurred.
USE_NETERR A network error occurred.
USE_CONN Connection is being made.
SE_RECONN Reconnecting.

ui1_asg_type
Contains values that determine several features. This member can be any of the following values:
Value Meaning
USE_WILDCARD Matches the type of the server's shared resources. Wildcards can be used only with the NetUseAdd function, and only when the ui1_local member is a null string.
USE_DISKDEV Disk device.
USE_SPOOLDEV Spooled printer.
USE_CHARDEV Communication device.
USE_IPC Interprocess communication (IPC).

ui1_refcount
Specifies how many files, directories, and other processes are open on the remote resource. This element is not used by the NetUseAdd function.
ui1_usecount
Specifies how many explicit connections (redirection with a local device name) or implicit UNC connections (redirection without a local device name) are established with the resource.

QuickInfo

  Windows NT: Requires version 3.1 or later.
  Windows: Unsupported.
  Windows CE: Unsupported.
  Header: Declared in lmuse.h.

See Also

Networking (Net) Overview, Net Structures, NetUseAdd, NetUserEnum, NetUseGetInfo