I tried mapping network drives via HKLM run registry myself recently without success. I suspect the HKLM Run registries are run at computer startup, not at logon, and not run in the user's context. Mapped network drives appear to be a user setting and therefore
need to be run in the user's context.
I even tried a logon script via the Local Group Policy. (I wanted all users to have these particular network drives only when logging on to a specific computer.) But that didn't seem to work either for some reason.
I would suggest placing a .bat script with the net use commands into the All Users StartMenu folder.
So, In Windows 7:
Open your prefered text editor such as notepad or notepad++. (You will have to run-as-admin if you have UAC enabled due to where we will be saving it.)
Type in your code:
@Echo OffNet use P: *\\Server\Share1* /Persistent:NoNet use Q: *\\Server\Share2* /Persistent:NoNet use G: *\\Server2\Share3* /Persistent:No
I used /Persistent:No because I am confident in the server connectivity and do not want to have to use a Net Use [Drive] /Delete in order to remove drives later. The script will be running everytime at each logon so I did not feel the need for it to reconnect
itself.
You may use a /Persistent:Yes if you wish, but this means that the drive will remain even if you later remove it from the logon script. As mentioned above, you can counteract this with a net use [drive] /delete.
Save the file as a .bat file to %ProgramData%\Microsoft\Windows\Start Menu\Programs\Startup
E.G.
C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup\MapNetworkDrives.bat
If you need to specify alternate credentials, you can do so with "Net Use Z: \Server\Share /User:Domain\Username Password" but be warned, this will save the password in plain text for anyone to read. And the script will be quite easily findable as it will
be in everyone's StartMenu -> Programs -> Startup folder. (Which means it's also easy for users to re-run the script if they've lost their drives for some reason. Or they could just log out and back in.)
This will also work for other Windows operating systems, even Windows 8 despite not having a Start Menu (the files are still there, and I can confirm that items in the startup folder will be run at logon), but the location you need to save the script in
might be different. If you right click on the folder in the start-menu, you can generally get the opion to "Open All Users". This should let you know where it is. Except for Windows 8 obviously... stupid not having a start-menu... Pretty sure it was in the
same location as Windows 7.