Warm hello to all seeing its my first post.

Now, how do we rename network drive names (not the drive lettors). Generally, the Use [drive letter:] \\$server\sharename will map the drive fine and dandy but assigns it a generic name based on some pre-defined Windows conventions e.g. marketing on server1(M:)

Now, I did some search on google and on this forum as well and all I could find was a VBS script which can achieve this easily, a copy below. However, I wish to do this from within Kix only and avoid launching another vb script. Is that possible with KiXtart? Thank you in advance.


http://www.computerperformance.co.uk/ezine/ezine60.htm
 Code:
' NameDrive.vbs
' VBScript to map a network drive.
' Authors Guy Thomas and Barry Maybury
' Version 1.3 - January 23rd 2005
' ----------------------------------------'
'
Option Explicit
Dim objNetwork, strDrive, objShell, objUNC
Dim strRemotePath, strDriveLetter, strNewName
'
strDriveLetter = "Y:"
strRemotePath = "\\alan\home"
strNewName = "GuyDives"

' Section to map the network drive
Set objNetwork = CreateObject("WScript.Network")
objNetwork.MapNetworkDrive strDriveLetter, strRemotePath

' Section which actually (re)names the Mapped Drive
Set objShell = CreateObject("Shell.Application")
objShell.NameSpace(strDriveLetter).Self.Name = strNewName

Wscript.Echo "Check : "& strDriveLetter & " for " & strNewName
WScript.Quit

' End of script.


Edited by Mart (2009-11-12 09:10 AM)
Edit Reason: Please use code tags when posting code.