View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
tolgag[_52_] tolgag[_52_] is offline
external usenet poster
 
Posts: 1
Default How to find the drive letter?

Hi,

With help of FileSystemObject you can get the driveletter of a path
like this :

Function readDriveLetter(pstrPath as String) as String

Dim fso, d
Set fso = CreateObject("Scripting.FileSystemObject")
Set d = fso.GetDrive(fso.GetDriveName(pstrPath))
readDriveLetter = d

End Functio

--
Message posted from http://www.ExcelForum.com