This post is a short novel, so bear with me...
I'd like to find an effective way to manage a set of shortcuts that point to network locations (e.g.
\\server-name\folder) that technically aren't just generic shortcuts (i.e. *.lnk files), which will ask me for credentials if needed. I have come up with a viable solution, but wanted to run my ideas (and "solution") by this community to see if there is a better way.
So first off, creating a generic shortcut (a *.lnk file) to the network locations works great, and the only reason I'm looking for an alternative is for use with the StandaloneStacks application (which emulates OSX shortcut stacks on Windows). With folder shortcuts, it attempts to drill down the folder structure, when instead I'd like it to simply show me the root folder in Explorer.
Anyway, some more requirements: I'm not allowed to join the domain. I'm stuck poking around the network by authenticating against each machine as needed. In addition, my network password expires every month so I don't want Windows to permanently remember my credentials or I'll get locked out (3 strikes you're out).
My first thought was to simply use
explorer.exe to launch the network location in an Explorer window, like so:
This works pretty well, but only when I've already been authenticated against the server and Windows is remembering my credentials. If I'm not already authenticated, running that command will take me to my home directory (e.g.,
I thought about wrapping this with a
runas with my network account:
runas.exe /netonly /user:domain\user "explorer.exe /separate,/e,/root,\\server-name\folder"
Ignoring the fact that I'd have to type my password every single time I wanted to launch a shortcut, this got me closer, except Windows doesn't pass the credentials in the manner I expected; it always shows an authentication failed message ("Unknown user name or bad password"). Due to my rapidly expiring passwords I'd rather not pipe in my password.
After some more digging I discovered the built-in
start command. I can simply put the following in a batch file and it will do what I want:
start /max "Folder Title" \\server-name\folder
This will launch explorer in a maximized window, take me to the folder, and ask for credentials if it's the first time logging in during my Windows session. The most annoying part is the flashing of the command prompt before it launches the folder. I tried setting the command window to run minimized, but then it also minimizes the prompt for credentials.
My solution so far is that I have a folder full of little batch files with start commands pointing to all of the locations on the network I frequently visit. I then created shortcuts to these batch files with prettier icons for use with StandaloneStacks.
So, aside from writing my own little utility to launch shortcuts to network locations, are there any other built-in things in Windows that would work and might be simpler than I what I settled on? I'm using 64-bit Windows 7.
Other caveats: I jump around from client to client so I can't permanently configure my machine in any way. This rules out creating network locations to the folders I'd like and then creating magic shortcuts to them (using their GUIDs). It also sort of rules out just adding bookmarks in Explorer to these locations (the stacks features is nice, such that I don't have to launch explorer and then pick a shortcut, but that isn't such a bad idea).