RSS

How-to map network drives based on network location

1 Comment | This entry was posted on Apr 14 2009

This has been driving me crazy and I cannot figure out how to do it. Here is my problem:
I have a work laptop that I obviously use at work as well as at home. At work I have 6 network drives that are mapped automatically if I log into my computer while at work. At home I have a Windows Home Server with 5 shares that I wrote a batch script to connect to them when I get home. The WHS Connector also adds a shortcut to the shares on my desktop but I want the shares mapped so I can use them as local drives in programs. I also had to write 3 more scripts (1 to disconnect my work drives, 1 to connect my work drives, and 1 to disconnect my home drives) in case I go between work and home without fully turning off my computer and instead just putting it to sleep. I am fairly certain this problem can be fixed with AutoIT or some other tool but I am just surprised this sort of functionality isn’t built into ANY operating system. My laptop has Vista and Linux Mint on it but I know this functionality isn’t in OSX either.
Is there anyone out there that can can suggest something to accomplish this? All I want is something that monitors what network I am connected to, and if that network happens to be home or work, map the appropriate drives. I am going to work on this in AutoIT but I am open to suggestions if you have any.
As soon as I find more information or someone points me to a solution I will update this post with how it works.
Leave your idea’s in the comments.