Jump to content

Reconnecting mapped network drives


eetaylog

Recommended Posts

I have several mapped network drives on a client pc in my bedroom. Is there a way to set them up so they automatically reconnect when i connect to the network tha theyre on?

 

Currently my client automatically connects to my bt broadband router when booting up (which is what i want), but when i want to connect to the mapped drives on my media server network to watch films etc (which is on a different router for reasons i wont go into) i have to manually go to my computer -> double click on each mapped drive to make it reconnect.

 

Im running Win7 btw.

Link to comment
Share on other sites

Do you need to use drive letters? could you not just use UNC paths in shortcuts on the desktop? (assuming they need to be used quite often)

 

No not really. I use a media centre front end on my client pc which uses the addresses of the mapped drives to find the video and music files on my server, so i need a way of 'waking up' the mapped drives so the software has somewhere to look.

Link to comment
Share on other sites

Have you tried UNC paths in the software? or is it Drive letters only?

 

*****************************

Update, Write a basic script to remap the drives, with the last line starting the software you run. Save as a VBS or BAT, and use this to load your Media Centre software.

Edited by bluliz
Link to comment
Share on other sites

Have you tried UNC paths in the software? or is it Drive letters only?

 

*****************************

Update, Write a basic script to remap the drives, with the last line starting the software you run. Save as a VBS or BAT, and use this to load your Media Centre software.

 

I like the idea of writing a execution script, it would save having to reconnect the drives and then launch the software. Not sure what the commands for reconnecting network drives would be though, ive only ever written a basic copy and paste .bat script. :mellow:

Link to comment
Share on other sites

Just do this in note pad, it will map the shares and thet start what ever program you want.

 

*******************

net use K:\ \\server\share\

net use L:\ \\server\share2\

Start "c:\program files\Media Software\Media Centre.exe"

 

*****************************

 

Replace the Letters and shares with the ones you use, and the software path with the correct one for the EXE (not shortcut) and save as a .bat

Edited by bluliz
Link to comment
Share on other sites

i think the command line is having problems with the spaces that are in the software address. The path to my software is:

 

C:\Program Files\Team MediaPortal\MediaPortal\MediaPortal.exe

 

but the .bat file throws its toys out of its pram when it reaches C:\Program because it cant handle the space that follows. Which character should i use? Ive tried removing the space, and also using underscore:

 

C:\Program_Files\Team_MediaPortal\MediaPortal\MediaPortal.exe

 

C:\ProgramFiles\TeamMediaPortal\MediaPortal\MediaPortal.exe

 

but neither work..?

Link to comment
Share on other sites

Use the quotation marks........

 

I already have have the address in quotation marks, i just posted the above address without them to show you the path.

 

By the way, im not sure that the START command works like that anyway. isnt everything in the quotation marks just the title of the command, and then the file path is typed immediately after, ie:

 

START "MediaPortal" C:\Program Files\Team MediaPortal\MediaPortal\MediaPortal.exe

 

At the moment when i try to run the bat file, i get the following command window (notice the address is being put in the title bar):

 

http://www.evo-host.co.uk/getimg/23079.jpg

Link to comment
Share on other sites

It should be a .cmd file anyway, not .bat... this ain't windows 95 anymore!! ;)

 

 

 

start "C:\Program Files\Team MediaPortal\MediaPortal\MediaPortal.exe" should work..

 

:pancake: oh yeah!

 

well i tried running it as a .cmd file instead, but still no dice. As a test ive even removed the net use commands, so that the only thing in the cmd file is:

 

start "C:\Program Files\Team MediaPortal\MediaPortal\MediaPortal.exe"

 

but it still wont launch the program? not sure whats going on.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...