[SOLVED] CMD.EXE was started with the above path as the current directory.

Status
Not open for further replies.
Hello

I keep losing acces to one of my networkshares when using vpn

To solve the issue, I created a .bat that does the following:

@Echo off
net use W:\\servername\directory
pause

It gives me this error:

CMD.EXE was started with the above path as the current directory.
UNC paths are not supported. Defaulting to Windows directory.


Can someone explain to me in layman terms what is going on?
I have googled the issue for quite a while now, but I am dumbfounded by the answers

Disclaimer: i'm a faaaaaaaaaaar from a scripting genius

As always, thank you guys for your insights
 
Solution
You're probably launching bat file from network location.
Launch it from local location instead (or at least network location, that has drive letter mapped to it).

BTW - there should be empty space between W: and \\servername\directory
Status
Not open for further replies.