Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

NET USE password with an ampersand 1

Status
Not open for further replies.

paulhung

Technical User
Feb 2, 2001
37
0
0
US
Trying to script the mapping of a network drive with the username and password in the command line. Looks something like this:

net use M: \\x.x.x.x\share pass&word /user:jschmoe

However, the following error would result:

System error 1326 has occurred.

Logon failure: unknown user name or bad password

'word' is not recognized as an internal or external command, operable program or batch file.



Anyone have a clue as to how to specify a password that has an ampersand in it? It really isn't an option to change the password without an ampersand.

Thanks
 
net use M: \\x.x.x.x\share "pass&word" /user:jschmoe

John
 
Naming conventions in Active Directory for computers, domains, sites, and OUs


These are old superseded MSKB which I use just for information about the "&" character.

Certificate Does Not Display the Ampersand (&) in a Company Name

NTLM Password Change Fails When Password Contains an Ampersand (&)



"The ampersand (&) character has special meaning...........If you wish to have the ampersand character appear literally as part of your command text, list it twice in direct succession." This was talking about Context Menu and Shell commands in some unknown link. It just shows again that the "&" character is a bit special.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top