![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
|
Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
br> br> |
| |||||||
![]() |
| | Thread Tools | Display Modes |
| | #2 (permalink) |
| Guest | RE: how to map network drives on a remote computer ? Do you mean you want to map a network drive to a remote machine or you want to map a network drive from a remote machine to a third machine -- Richard Siddaway Please note that all scripts are supplied "as is" and with no warranty Blog: http://richardsiddaway.spaces.live.com/ PowerShell User Group: http://www.get-psuguk.org.uk "Nicopilami" wrote: > Hi everybody, i would like to map a new network drive on a remote > computer under an admin account, but i didn't find how i could do it. > Would you have an idea ? > > thx > bye > Nico > > |
| | #3 (permalink) |
| Guest | Re: how to map network drives on a remote computer ? On Aug 2, 12:20 am, Nicopilami <n.chauss...@gmail.com> wrote: > Hi everybody, i would like to map a new network drive on a remote > computer under an admin account, but i didn't find how i could do it. > Would you have an idea ? > > thx > bye > Nico I have something like this in my profile, which allows me to map a network drive if it hasn't been done yet: & { if ( !( Test-Path Z: ) ) { $net = New-Object -ComObject WScript.Network $password = Read-Host -AsSecureString "Password for mapped drive" $bstr = [System.Runtime.InteropServices.Marshal]::SecureStringToBSTR( $password ) $password = [System.Runtime.InteropServices.Marshal]::PtrToStringAuto( $bstr ) [System.Runtime.InteropServices.Marshal]::ZeroFreeBSTR( $bstr ) $net.MapNetworkDrive( "Z:", "\\<server>\<share>", "false", "<username>", $password ) } } Maybe this will get you started. The Read-Host stuff is just so I don't have to hard-code a password in my $profile. Good luck. Jeff |
| | #4 (permalink) |
| Guest | Re: how to map network drives on a remote computer ? In message <1185988823.042667.253450@b79g2000hse.googlegroups.com>, Nicopilami <n.chaussard@gmail.com> writes >Hi everybody, i would like to map a new network drive on a remote >computer under an admin account, but i didn't find how i could do it. >Would you have an idea ? net use x: \\foobar\share Where \\foobar is the server and share is the share name. You can also do this deeper, e.g.: net use x:\\foobar\share\folder\folder2\folder3 Where \folder\folder2\folder3 are folders within the share. you can use net use within a PowerShell script. Thomas -- Thomas Lee doctordns@gmail.com MVP - Admin Frameworks and Security |
| | #5 (permalink) |
| Guest | Re: how to map network drives on a remote computer ? Mapped network drives are per user things, not per computer things. So, if the intent is to make a mapped network drive available to anyone that logs on to a computer, put the appropriate net use command into the All Users startup folder so it will be executed at every logon. \\computername\c$\documents and settings\All Users\Start menu\programs\startup -- Bruce Sanderson MVP http://members.shaw.ca/bsanders/ It's perfectly useless to know the right answer to the wrong question. "Nicopilami" <n.chaussard@gmail.com> wrote in message news:1185988823.042667.253450@b79g2000hse.googlegroups.com... > Hi everybody, i would like to map a new network drive on a remote > computer under an admin account, but i didn't find how i could do it. > Would you have an idea ? > > thx > bye > Nico > |
| |
| |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Mapped Drives and Remote Desktop | randy.lane | Vista networking & sharing | 2 | 07-14-2008 06:34 PM |
| Missing drives (harddrive, cdrom and maaped network drives) | Martin Rhodin | Vista General | 1 | 02-26-2008 02:20 PM |
| Vista: This Computer can't connect to the Remote Computer | Wes | Vista networking & sharing | 0 | 06-20-2007 06:41 PM |
| Computer Management: Can't connect to a remote computer | Paul | Vista networking & sharing | 0 | 05-08-2007 06:17 PM |
| remote assistance to local network computer | Chris Cowles | Vista networking & sharing | 3 | 04-03-2007 10:09 PM |