Author Topic: IDrive.Path Property  (Read 2940 times)

0 Members and 1 Guest are viewing this topic.

Online José Roca

  • Administrator
  • Hero Member
  • *****
  • Posts: 2517
  • User-Rate: +209/-0
  • Gender: Male
IDrive.Path Property
« on: July 14, 2008, 05:15:59 AM »

The following code illustrates the use of the Path property:

Code: [Select]
#INCLUDE "windows.inc"
#INCLUDE "scrrun.inc"

DIM fso AS IFileSystem
DIM pDrive AS IDrive

' Create an instance of the FileSystemObject
fso = NEWCOM "Scripting.FileSystemObject"
' Get a reference to the IDrive interface
pDrive = fso.GetDrive((UCODE$("C:\MyFolder\MyFile.txt"))
' Get the path name
STDOUT ACODE$(pDrive.Path(pDrive))