
how to get short path name
Quote:
> Hello,
> I am new to VBscript. I would like to know how to get the
> windows short path name.
> Thanks,
> RK
From the WSH 5.6 documentation:
http://msdn.microsoft.com/downloads/sample.asp?url=/MSDN-FILES/027/00...
ompositedoc.xml
Function ShowShortName(filespec)
Dim fso, f, s
Set fso = CreateObject("Scripting.FileSystemObject")
Set f = fso.GetFile(filespec)
s = "The short name for " & UCase(f.Name) & "<BR>"
s = s & "is: " & f.ShortName
ShowShortName = s
End Function