Net Use
Connects a computer to or disconnects a computer from a shared resource, or
displays information about computer connections. The command also controls
persistent net connections.
net use [devicename | *] [\\computername\sharename[\volume]] [password | *]] [/user:[domainname\]username] [[/delete] | [/persistent:{yes | no}]]
net use devicename [/home[password | *]] [/delete:{yes | no}]
net use [/persistent:{yes | no}]
Parameters
none
Type net use without parameters to get a list of network connections.
devicename
Assigns a name to connect to the resource or specifies the device to be
disconnected. There are two kinds of devicenames: disk drives (D: through Z:) and
printers (LPT1: through LPT3). Type an asterisk instead of a specific devicename
to assign the next available devicename.
\\computername\sharename
Is the name of the server and the shared resource. If the computername
contains blank characters, enclose the double backslash (\\) and the computername in
quotation marks (" "). The computername may be from 1 to 15 characters long.
\volume
Specifies a NetWare volume on the server. You must have Client Service for
NetWare (Windows NT Workstation) or Gateway Service for NetWare (Windows NT
Server) installed and running to connect to NetWare servers,
password
Is the password needed to access the shared resource.
*
Produces a prompt for the password. The password is not displayed when you
type it at the password prompt.
/user
Specifies a different username with which the connection is made.
domainname
Specifies another domain. For example, net use d: \\server\share /user:admin\mariel connects the user mariel as if the connection were made from the admin
domain. If domain is omitted, the current logged on domain is used.
username
Specifies the username with which to log on.
/home
Connects a user to their home directory.
/delete
Cancels the specified network connection. If the user specifies the connection
with an asterisk, all network connections are cancelled.
/persistent
Controls the use of persistent network connections. The default is the setting
used last. Deviceless connections are not persistent.
yes
Saves all connections as they are made, and restores them at next logon.
no
Does not save the connection being made or subsequent connections; existing
connections will be restored at next logon. Use the /delete switch to remove persistent connections.
More Information About Net Use
Net Use--Notes
Net Use--Examples