I'm trying to set up a net use .bat
file to automatically map a webDAV-folder on Windows-boot, but I can't, for the love of god, make it work. I tried like 30 combinations suggested on the Windows-forum, superuser and god knows where but none of them work.
My problem is, that the net use
command I'm using works when I omit the password but when I insert the password and execute the .bat
it doesn't (the password entered here is only true for special characters, not for the numbers and letters):
net use Y: \\www.example.us@SSL\webdav /user:user01 1A*gX_~)a"];->Ku
When I simply put the above command without the password in a .bat
file and execute it, I get prompted for a password and when I enter it, the drive get's mapped without problem. But when I put the password in the command and execute it, the CMD-window just opens and closes immediately without mapping the drive. I'm starting to think it is because the password was created with the keepass generator and the command doesn't like one of the special characters in it. That's why I pasted the password above, so someone might tell me if that's the problem. Also keep in mind, that the command without the password works, so I guess the command without the password is not the problem.
Thanks for the help.
pause
command afternet use
to prevent the window from closing, to see an error message... And try to run the.bat
as the administrator using mouse right-click.>
character? The sequence>Ku
causes the output of the command in front of it to be redirected to a file namedKu
. Only the characters before that will be interpreted as password.