3

So, I have a poorly designed application (surprise!) to support. It opens a "browse for folder" Dialog, which is all well and good, except the user needs to select a share on another server. I figured I'd just map a drive there for them, but they need access to any one of 60 shares on the server.

I need a way to map \server\ to a folder so they can see all the available shares, but windows will only let you map \server\share, which defeats the purpose.

I just need my users to be able to see all of the available shares on a server from within that "Browse for Folder" dialog.

Any ideas on how this can be accomplished?

  • 1
    Have you tried typing \\server\ into the file name field of your "browse for folder dialogue" and hit enter? – duenni Jan 29 '15 at 14:22
  • There is no name field, otherwise this would have been much more simple. Pic – michael.clyne Jan 29 '15 at 14:23
  • Maybe you could create a new share which contains a symlink to the other shares. mklink is your friend on Windows. Just a quick idea... – duenni Jan 29 '15 at 14:29
  • I did temporarily, but We add and remove shares all the time. Each one is for an ongoing project, so we'd need to keep these links updated, which I'm hoping to avoid if at all possible – michael.clyne Jan 29 '15 at 14:31
  • Not shortcuts but symlinks. EDIT I realize it would be better to use a Junction here. Something like mklink /J c:\shares\allyourshares \\server\newshare on the server. Then you can mount \\server\newshare which will point to all your other shares. Use with caution, never tested such a thing. – duenni Jan 29 '15 at 14:37
2

You need to map to the IPC$ (Inter-Process Communication) share. Just run the following from a command prompt or script.

net use \\<server> /user:<domain\username> *

This will create a cached security token, for that user, for that server, such that any shares accessed will use this cached token by default and will not prompt the user.

The token stays cached until you logout, so this works well in a login script. The asterisk (*) tells the net command to prompt the user for a password, or you can replace the asterisk with the user's password for scripting. Also, DO NOT include a trailing slash after the server name (\\server ...or \\server\IPC$ ...not \\server\) because that points to a share, not the IPC.

| improve this answer | |
0

You can share the root volume (Although that's probably not advisable unless this is a volume that contains only shared folders. If it's the OS volume then it's definitely not advisable). In Windows, each fixed disk volume is shared for administrative purposes and hidden (using the $ sign in the share name). You can share each volume again by assigning a share name of your choosing.

So you can share the root volume and then map a drive letter to that share. When the users connect to the mapped drive they'll see all of the folders on that volume.

For example:

Server = fileserver

Volume share name = Root

Mapped drive = Q = \\fileserver\root

Browsing Q = every folder on the root volume of fileserver

| improve this answer | |
  • Unfortunately, the shares are on different drives (3 per drive) – michael.clyne Jan 29 '15 at 16:07
0

You can create a symbolic Link to the share and then let them access the symbolic links. Create a batch file that you can run on the users machines that sets it up.

mkdir c:\servershares
cd c:\servershares

mklink /D share1 \\server\share1
mklink /D share2 \\server\share2
mklink /D share3 \\server\share3
| improve this answer | |
0

You can also create a DFS share that contains all the shares on that server.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.